diff --git a/src/api/02_organizational/api.organization.ts b/src/api/02_organizational/api.organization.ts index b0c28c673..d4af7e15d 100644 --- a/src/api/02_organizational/api.organization.ts +++ b/src/api/02_organizational/api.organization.ts @@ -29,6 +29,7 @@ export default { orgPosMove: `${orgPos}/move`, organizationShortName: `${organization}/sort`, organizationPublishGet: `${organization}/get/publish`, + orgPosDNA: `${orgPos}/dna`, //สืบทอดตำแหน่ง orgPosExecutiveById: (id: string) => `${orgPos}/executive/${id}`, orgPosHistory: (id: string) => `${orgPos}/history/${id}`, diff --git a/src/modules/02_organizationalNew/components/DialogFormPosition.vue b/src/modules/02_organizationalNew/components/DialogFormPosition.vue index 08dbc21eb..301a281c7 100644 --- a/src/modules/02_organizationalNew/components/DialogFormPosition.vue +++ b/src/modules/02_organizationalNew/components/DialogFormPosition.vue @@ -736,17 +736,6 @@ async function emitSearch(keyword: string, typeSelect: string) { }} - - - - เลือกสืบทอดตำแหน่ง - diff --git a/src/modules/02_organizationalNew/components/DialogInherit.vue b/src/modules/02_organizationalNew/components/DialogInherit.vue new file mode 100644 index 000000000..1caa06bd4 --- /dev/null +++ b/src/modules/02_organizationalNew/components/DialogInherit.vue @@ -0,0 +1,410 @@ + + + + + + + + + + + + + เลือกหน่วยงาน + + + + + + + + + + + + + + + {{ prop.node.orgTreeName }} + + + {{ prop.node.orgCode == null ? null : prop.node.orgCode }} + {{ + prop.node.orgTreeShortName == null + ? null + : prop.node.orgTreeShortName + }} + + + + + + + + + + เลือกตำแหน่งที่ต้องการสืบทอด + + + + + + + + + + + + + + + + {{ col.label }} + + + + + + + + + + + + {{ props.rowIndex + 1 }} + + + + {{ col.value }} + + + + + + + + + + + + + + + + + + + + diff --git a/src/modules/02_organizationalNew/components/tableTree.vue b/src/modules/02_organizationalNew/components/tableTree.vue index a07497da4..90f798da9 100644 --- a/src/modules/02_organizationalNew/components/tableTree.vue +++ b/src/modules/02_organizationalNew/components/tableTree.vue @@ -22,6 +22,8 @@ import DialogSort from "@/modules/02_organizationalNew/components/DialogSortPosi import DialogMovePos from "@/modules/02_organizationalNew/components/DialogMovePos.vue"; import DialogHistoryPos from "@/modules/02_organizationalNew/components/DialogHistoryPos.vue"; import DialogSelectPerson from "@/modules/02_organizationalNew/components/DialogSelectPerson.vue"; +import DialogInherit from "@/modules/02_organizationalNew/components/DialogInherit.vue"; + /** importStore*/ import { useOrganizational } from "@/modules/02_organizationalNew/store/organizational"; import { useCounterMixin } from "@/stores/mixin"; @@ -78,6 +80,12 @@ const listMenu = ref([ type: "MOVE", color: "positive", }, + { + label: "สืบทอดตำแหน่ง", + icon: "mdi-account-multiple-outline", + type: "INHERIT", + color: "deep-orange", + }, { label: "ประวัติตำแหน่ง", icon: "history", @@ -356,6 +364,12 @@ function removePerson(id: string) { ); } +const modalDialogInherit = ref(false); +function onClickInherit(id: string) { + modalDialogInherit.value = !modalDialogInherit.value; + rowId.value = id; +} + /** ดึงข้อมูลสถิติจำนวนด้านบน*/ function getSummary() { showLoader(); @@ -655,6 +669,8 @@ async function genReportDoc(data: any) { ? onClickMovePos(props.row.id, 'SINGER') : item.type === 'HISTORY' ? onClickHistoryPos(props.row.id) + : item.type === 'INHERIT' + ? onClickInherit(props.row.id) : null " > @@ -798,12 +814,16 @@ async function genReportDoc(data: any) { + + + +