diff --git a/src/modules/07_insignia/components/2_Manage/Tab1.vue b/src/modules/07_insignia/components/2_Manage/Tab1.vue index eb88cffc5..267a74fb4 100644 --- a/src/modules/07_insignia/components/2_Manage/Tab1.vue +++ b/src/modules/07_insignia/components/2_Manage/Tab1.vue @@ -42,19 +42,7 @@ const dialogDesc = ref(""); // แจ้งเตือน const dialogWarn = ref(false); -const checkboxData = ref([ - { id: 1, name: "มีโทษทางวินัย", val: true }, - { - id: 2, - name: "ไม่ได้เลื่อนเงินเดือน/ไม่ได้เลื่อนขั้น เนื่องจากลาเกิน", - val: false, - }, - { - id: 3, - name: "ผลการประเมินการปฏิบัติราชการในรอบ 5 ปี ต่ำกว่าระดับดี (น้อยกว่าร้อยละ 70)", - val: false, - }, -]); +const checkboxData = ref([]); const organizationOptions = ref([{ id: "1", name: "ทั้งหมด" }]); const visibleColumns = ref([ @@ -641,7 +629,24 @@ const clickShowreson = (name: string, requestNote: string) => { const clickCloseReson = () => { dialogNote.value = false; }; -const clickShowWarn = () => { +const clickShowWarn = ( + markDiscipline: boolean, + markLeave: boolean, + markRate: boolean +) => { + checkboxData.value = [ + { id: 1, name: "มีโทษทางวินัย", val: markDiscipline }, + { + id: 2, + name: "ไม่ได้เลื่อนเงินเดือน/ไม่ได้เลื่อนขั้น เนื่องจากลาเกิน", + val: markLeave, + }, + { + id: 3, + name: "ผลการประเมินการปฏิบัติราชการในรอบ 5 ปี ต่ำกว่าระดับดี (น้อยกว่าร้อยละ 70)", + val: markRate, + }, + ]; dialogWarn.value = true; }; @@ -805,7 +810,6 @@ const clickShowWarn = () => { {{ col.label }} - + แจ้งเตือน + { - diff --git a/src/modules/07_insignia/store.ts b/src/modules/07_insignia/store.ts index da03624e6..19cb607f8 100644 --- a/src/modules/07_insignia/store.ts +++ b/src/modules/07_insignia/store.ts @@ -55,8 +55,12 @@ export const useInsigniaDataStore = defineStore("insignia", () => { dateSend: date2Thai(e.requestDate), requestNote: e.requestNote, employeeType: profileType(e.profileType), - reason: e.reason - + reason: e.reason, + markDiscipline: e.markDiscipline, + markLeave: e.markLeave, + markRate: e.markRate, + isApprove: e.isApprove, + statusMark: e.markDiscipline === true || e.markLeave === true || e.markRate === true ? true : false })); rows.value = await datalist; listinsignia.value = await datalist; @@ -146,6 +150,7 @@ export const useInsigniaDataStore = defineStore("insignia", () => { } } + return { roundId, optionRound,