From bbf7a5ea1c685cd64dd080e214a6320e7a79ca3d Mon Sep 17 00:00:00 2001 From: setthawutttty Date: Thu, 24 Oct 2024 13:08:59 +0700 Subject: [PATCH 1/2] =?UTF-8?q?=E0=B9=81=E0=B8=81=E0=B9=89=20=E0=B8=AA?= =?UTF-8?q?=E0=B9=88=E0=B8=87=E0=B9=84=E0=B8=9B=E0=B8=AA=E0=B8=B7=E0=B8=9A?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../components/PopupSendToNext.vue | 24 +++++++++++-------- 1 file changed, 14 insertions(+), 10 deletions(-) diff --git a/src/modules/11_discipline/components/PopupSendToNext.vue b/src/modules/11_discipline/components/PopupSendToNext.vue index 8ee5bffba..92efc0c12 100644 --- a/src/modules/11_discipline/components/PopupSendToNext.vue +++ b/src/modules/11_discipline/components/PopupSendToNext.vue @@ -72,16 +72,20 @@ const initialPagination = ref({ /** ฟังชั่นส่งคนไปออกคำสั่ง */ function onclickSend() { - if (props.title == "ส่งไปพักราชการ") { - dialogConfirm( - $q, - async () => { - emit("returnPerson", selected.value); - modal.value = false; - }, - `ยืนยันการ${props.title}`, - `ต้องการยืนยันการ${props.title}หรือไม่` - ); + if (props.title == "ส่งไปพักราชการ" || props.title == "ส่งไปสืบสวน") { + if (selected.value.length === 0) { + dialogMessageNotify($q, "กรุณาเลือกอย่างน้อย 1 บุคคล"); + } else { + dialogConfirm( + $q, + async () => { + emit("returnPerson", selected.value); + modal.value = false; + }, + `ยืนยันการ${props.title}`, + `ต้องการยืนยันการ${props.title}หรือไม่` + ); + } } else { if (selected.value.length === 0) { dialogMessageNotify($q, "กรุณาเลือกอย่างน้อย 1 บุคคล"); From 4fd13b672bbf73ea8828c5d225d2ebc90a4e52b4 Mon Sep 17 00:00:00 2001 From: setthawutttty Date: Thu, 24 Oct 2024 13:19:39 +0700 Subject: [PATCH 2/2] =?UTF-8?q?=E0=B8=9B=E0=B8=A3=E0=B8=B1=E0=B8=9A?= =?UTF-8?q?=E0=B8=9F=E0=B8=AD=E0=B8=A3=E0=B9=8C=E0=B8=A1=E0=B9=80=E0=B8=9E?= =?UTF-8?q?=E0=B8=B4=E0=B9=88=E0=B8=A1=E0=B8=9B=E0=B8=A3=E0=B8=B0=E0=B8=98?= =?UTF-8?q?=E0=B8=B2=E0=B8=99/=E0=B8=81=E0=B8=A3=E0=B8=A3=E0=B8=A1?= =?UTF-8?q?=E0=B8=81=E0=B8=B2=E0=B8=A3=20=E0=B8=A3=E0=B8=AD=20API=20list?= =?UTF-8?q?=20=E0=B8=84=E0=B8=99=E0=B8=AD=E0=B8=B1=E0=B8=99=E0=B9=83?= =?UTF-8?q?=E0=B8=AB=E0=B8=A1=E0=B9=88?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/api/05_placement/api.probation.ts | 2 + .../DialogOrder/DialogSendToCommand.vue | 15 +- .../probation/FormAppoint/FormAppoint.vue | 202 +++++++++++------- 3 files changed, 139 insertions(+), 80 deletions(-) diff --git a/src/api/05_placement/api.probation.ts b/src/api/05_placement/api.probation.ts index 48a46c8cb..fca9c49a0 100644 --- a/src/api/05_placement/api.probation.ts +++ b/src/api/05_placement/api.probation.ts @@ -87,4 +87,6 @@ export default { appointMain, appointMainList:(id:string)=>`${appointMain}/list/${id}`, + + orgProfileDirector:`${orgProfile}/profile/commander-director` }; diff --git a/src/modules/05_placement/components/probation/DialogOrder/DialogSendToCommand.vue b/src/modules/05_placement/components/probation/DialogOrder/DialogSendToCommand.vue index 0a9bf839a..83c0480d3 100644 --- a/src/modules/05_placement/components/probation/DialogOrder/DialogSendToCommand.vue +++ b/src/modules/05_placement/components/probation/DialogOrder/DialogSendToCommand.vue @@ -16,6 +16,17 @@ const selected = ref([]); const mixin = useCounterMixin(); const { dialogConfirm } = mixin; +const dataMapToSend = computed(() => { + return selected.value.map((i: any) => ({ + id: i.id, + profileId: null, + prefix: null, + firstName: null, + lastName: null, + citizenId: null, + })); +}); + const filterKeyword = defineModel("filterKeyword", { required: true }); const rows = defineModel("rows", { required: true }); /** props*/ @@ -236,7 +247,7 @@ watchEffect(() => { diff --git a/src/modules/05_placement/components/probation/FormAppoint/FormAppoint.vue b/src/modules/05_placement/components/probation/FormAppoint/FormAppoint.vue index c70ded540..91993d4c1 100644 --- a/src/modules/05_placement/components/probation/FormAppoint/FormAppoint.vue +++ b/src/modules/05_placement/components/probation/FormAppoint/FormAppoint.vue @@ -1,6 +1,6 @@