diff --git a/Laravel/app/Http/Controllers/API/Admin/YeWu/PlanListController.php b/Laravel/app/Http/Controllers/API/Admin/YeWu/PlanListController.php
index d7ea1f7..6296242 100644
--- a/Laravel/app/Http/Controllers/API/Admin/YeWu/PlanListController.php
+++ b/Laravel/app/Http/Controllers/API/Admin/YeWu/PlanListController.php
@@ -724,6 +724,7 @@ public function SaveLockedCount(Request $request)
$userid = $request->get('userid');
$roster_detail_id = request('roster_detail_id');
$locked_counts = request('locked_counts');
+ $locked_remark = request('locked_remark');
if (empty($roster_detail_id)) {
return \Yz::echoError1('计划明细ID不能为空');
@@ -791,6 +792,11 @@ public function SaveLockedCount(Request $request)
}
}
+ // 更新占位备注(时段级,无条件覆盖)
+ DB::table('s_source_roster_detail')
+ ->where('id', $roster_detail_id)
+ ->update(['locked_remark' => $locked_remark ?? null]);
+
// 有变更时记录日志
if (!empty($changes)) {
DB::table('s_source_roster_detail_log')->insert([
@@ -1196,6 +1202,7 @@ public function BatchChangeLocked(Request $request)
}
$ids = request('ids');
$coutsInfo = request('coutsInfo');
+ $locked_remark = request('locked_remark');
if (empty($ids) || empty($coutsInfo)) {
return \Yz::echoError1('参数错误');
}
@@ -1238,6 +1245,10 @@ public function BatchChangeLocked(Request $request)
AND appointment_type_id IN ({$atypeIdsStr})";
$u2 = DB::update($sql);
if ($u2 !== false) {
+ // 更新占位备注(时段级,无条件覆盖)
+ DB::table('s_source_roster_detail')
+ ->whereIn('id', array_map('intval', $ids))
+ ->update(['locked_remark' => $locked_remark ?? null]);
return \Yz::Return(true, '批量占位成功', []);
} else {
return \Yz::echoError1('批量占位失败');
diff --git a/Laravel/app/Http/Controllers/API/Admin/YeWu/WorkMainController.php b/Laravel/app/Http/Controllers/API/Admin/YeWu/WorkMainController.php
index a51b4ff..6a7318a 100644
--- a/Laravel/app/Http/Controllers/API/Admin/YeWu/WorkMainController.php
+++ b/Laravel/app/Http/Controllers/API/Admin/YeWu/WorkMainController.php
@@ -217,7 +217,7 @@ public function GetList(Request $request)
->leftJoin('s_period','s_list.reservation_time','=','s_period.id')
->leftJoin('s_department_resources','s_list.reservation_sources','=','s_department_resources.id')
->select('s_list.*','s_period.period_begin_time','s_period.period_end_time','s_department_resources.department_resources_name')
- ->where(['s_list.is_del'=>0,'s_list.is_nullify'=>0]);
+ ->where(['s_list.is_del'=>0]);
if($userInfo[0]->group==2){
// $list=$list->whereIn('warddesc', explode(",", $userInfo[0]->ward));
$list=$list->where(['wardcode'=> $department->department_number]);
@@ -272,8 +272,15 @@ public function GetList(Request $request)
$list = $list->whereBetween('s_list.reservation_date', $searchInfo['dateRange']);
}
}
- if (isset($searchInfo['list_status'])) {
- $list = $list->where('s_list.list_status', $searchInfo['list_status']);
+ if (isset($searchInfo['list_status']) && $searchInfo['list_status'] !== '' && $searchInfo['list_status'] !== null) {
+ if ($searchInfo['list_status'] === 'nullify') {
+ $list = $list->where('s_list.is_nullify', 1);
+ } else {
+ $list = $list->where('s_list.is_nullify', 0)
+ ->where('s_list.list_status', $searchInfo['list_status']);
+ }
+ } else {
+ $list = $list->where('s_list.is_nullify', 0);
}
if (isset($searchInfo['patient_type'])) {
$list = $list->where('s_list.patient_type', $searchInfo['patient_type']);
@@ -303,7 +310,7 @@ public function GetList(Request $request)
//动态排序
$orderField = $searchInfo['orderField'] ?? '';
$orderDirection = ($searchInfo['orderDirection'] ?? '') == 'ascending' ? 'asc' : 'desc';
- $allowedFields = ['reg_num', 'episodeid', 'user_name', 'user_sex', 'user_brithday', 'entrust', 'is_pay', 'list_status', 'reservation_department', 'user_phone', 'reservation_time', 'entrust_date_time'];
+ $allowedFields = ['reg_num', 'episodeid', 'user_name', 'user_sex', 'user_brithday', 'entrust', 'is_pay', 'list_status', 'reservation_department', 'user_phone', 'reservation_time', 'reservation_date', 'entrust_date_time'];
if (!empty($orderField) && in_array($orderField, $allowedFields)) {
if ($orderField === 'reservation_time') {
$list = $list->orderByRaw("CONCAT(IFNULL(s_list.reservation_date,''), ' ', IFNULL(s_period.period_begin_time,'')) $orderDirection");
diff --git a/YiJi-admin/src/views/AppointmentMngr/PlanList.vue b/YiJi-admin/src/views/AppointmentMngr/PlanList.vue
index f56ab44..dd70e14 100644
--- a/YiJi-admin/src/views/AppointmentMngr/PlanList.vue
+++ b/YiJi-admin/src/views/AppointmentMngr/PlanList.vue
@@ -287,6 +287,16 @@
+
+
+
@@ -352,6 +362,16 @@
合计
占用: {{ batchOccupyTotalLocked }}
+
+
+
@@ -1001,6 +1021,7 @@
let batchOccupyRunning = ref(false)
let batchOccupyForm = ref([])
let batchOccupyLimits = ref({}) // { [appointment_type_id]: { limited: bool, maxValue: number } }
+ let batchLockedRemark = ref('')
const initBatchOccupyForm = () => {
batchOccupyForm.value = batchChannels.map(ch => ({
appointment_type_id: ch.id,
@@ -1024,6 +1045,7 @@
return
}
initBatchOccupyForm()
+ batchLockedRemark.value = ''
// 从 planTableData 中提取已选号源的各渠道剩余号源(count - used_count),取最小值
const selectedIds = new Set(selectedPlanArr.value)
const channelRemaining = {} // { [appointment_type_id]: number[] }
@@ -1078,7 +1100,8 @@
try {
const res = await PlanListBatchChangeLocked({
ids: ids,
- coutsInfo: coutsInfo
+ coutsInfo: coutsInfo,
+ locked_remark: batchLockedRemark.value
})
batchOccupyRunning.value = false
if (res && res.status) {
@@ -1164,7 +1187,8 @@
loading.value = true
SaveLockedCount({
roster_detail_id: ZhanWeiInfo.value.id,
- locked_counts: locked_counts
+ locked_counts: locked_counts,
+ locked_remark: ZhanWeiInfo.value.locked_remark || ''
}).then(res => {
loading.value = false
if (res.status) {
diff --git a/YiJi-admin/src/views/AppointmentMngr/PlanListAdmin.vue b/YiJi-admin/src/views/AppointmentMngr/PlanListAdmin.vue
index 1ef4832..165771b 100644
--- a/YiJi-admin/src/views/AppointmentMngr/PlanListAdmin.vue
+++ b/YiJi-admin/src/views/AppointmentMngr/PlanListAdmin.vue
@@ -287,6 +287,16 @@
+
+
+
@@ -352,6 +362,16 @@
合计
占用: {{ batchOccupyTotalLocked }}
+
+
+
@@ -1016,6 +1036,7 @@
let batchOccupyRunning = ref(false)
let batchOccupyForm = ref([])
let batchOccupyLimits = ref({}) // { [appointment_type_id]: { limited: bool, maxValue: number } }
+ let batchLockedRemark = ref('')
const initBatchOccupyForm = () => {
batchOccupyForm.value = batchChannels.map(ch => ({
appointment_type_id: ch.id,
@@ -1039,6 +1060,7 @@
return
}
initBatchOccupyForm()
+ batchLockedRemark.value = ''
// 从 planTableData 中提取已选号源的各渠道剩余号源(count - used_count),取最小值
const selectedIds = new Set(selectedPlanArr.value)
const channelRemaining = {} // { [appointment_type_id]: number[] }
@@ -1094,7 +1116,8 @@
const res = await PlanListBatchChangeLocked({
ids: ids,
coutsInfo: coutsInfo,
- department_id: searchInfo.value.department_id
+ department_id: searchInfo.value.department_id,
+ locked_remark: batchLockedRemark.value
})
batchOccupyRunning.value = false
if (res && res.status) {
@@ -1180,7 +1203,8 @@
loading.value = true
SaveLockedCount({
roster_detail_id: ZhanWeiInfo.value.id,
- locked_counts: locked_counts
+ locked_counts: locked_counts,
+ locked_remark: ZhanWeiInfo.value.locked_remark || ''
}).then(res => {
loading.value = false
if (res.status) {
diff --git a/YiJi-admin/src/views/YeWu/MainList.vue b/YiJi-admin/src/views/YeWu/MainList.vue
index 8a38360..cfd1c50 100644
--- a/YiJi-admin/src/views/YeWu/MainList.vue
+++ b/YiJi-admin/src/views/YeWu/MainList.vue
@@ -30,6 +30,7 @@
+
@@ -102,15 +103,18 @@
-
+
- 申请中
- 已预约
- 登记
- 完成
+ 已作废
+
+ 申请中
+ 已预约
+ 登记
+ 完成
+
@@ -146,12 +150,12 @@
否
-
+
{{ scope.row.reservation_date }}
-
+
{{scope.row.period_begin_time.substring(0, 5)}}~{{scope.row.period_end_time.substring(0, 5)}}
@@ -459,6 +463,9 @@
GetList()
}
let tableSelected = ref([])
+ const checkSelectable = (row) => {
+ return row.is_nullify !== 1
+ }
const handleSelect = (e) => {
if (e.length > 1) {
const firstStatus = e[0].list_status;