From 7a09977cab7ba467ea642d069ce1bdff3176a7fc Mon Sep 17 00:00:00 2001 From: "DESKTOP-1R2VSQH\\Lenovo ThinkPad E490" Date: Thu, 15 Feb 2024 13:11:11 +0700 Subject: [PATCH] =?UTF-8?q?=E0=B9=82=E0=B8=84=E0=B8=A3=E0=B8=87=E0=B8=AA?= =?UTF-8?q?=E0=B8=A3=E0=B9=89=E0=B8=B2=E0=B8=87=E0=B8=AD=E0=B8=B1=E0=B8=95?= =?UTF-8?q?=E0=B8=A3=E0=B8=B2=E0=B8=81=E0=B8=B3=E0=B8=A5=E0=B8=B1=E0=B8=87?= =?UTF-8?q?=20=3D>=20=E0=B8=97=E0=B8=B1=E0=B8=A2=E0=B8=97=E0=B8=B5?= =?UTF-8?q?=E0=B9=88?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../02_organizationalNew/components/TreeTable.vue | 5 ++++- .../02_organizationalNew/components/TreeView.vue | 1 + .../interface/response/organizational.ts | 5 ++++- .../02_organizationalNew/store/organizational.ts | 10 ++++++---- 4 files changed, 15 insertions(+), 6 deletions(-) diff --git a/src/modules/02_organizationalNew/components/TreeTable.vue b/src/modules/02_organizationalNew/components/TreeTable.vue index 2dbfa385c..b7453f5f3 100644 --- a/src/modules/02_organizationalNew/components/TreeTable.vue +++ b/src/modules/02_organizationalNew/components/TreeTable.vue @@ -553,9 +553,12 @@ async function onClickDownloadReport(val: string, name: string) { 1 }} +
+ {{ props.row.isSit ? col.value + " " + "(ทับที่)" : col.value }} +
- {{ col.value }} + {{ col.value ? col.value : "-" }}
diff --git a/src/modules/02_organizationalNew/components/TreeView.vue b/src/modules/02_organizationalNew/components/TreeView.vue index 98c0507b4..881f0beca 100644 --- a/src/modules/02_organizationalNew/components/TreeView.vue +++ b/src/modules/02_organizationalNew/components/TreeView.vue @@ -65,6 +65,7 @@ async function fetchDataTree(id: string) { nodeTree.value = data; selected.value = ""; nodeId.value = ""; + store.treeId = ""; }) .catch((err) => { messageError($q, err); diff --git a/src/modules/02_organizationalNew/interface/response/organizational.ts b/src/modules/02_organizationalNew/interface/response/organizational.ts index 919362595..d674b5773 100644 --- a/src/modules/02_organizationalNew/interface/response/organizational.ts +++ b/src/modules/02_organizationalNew/interface/response/organizational.ts @@ -111,6 +111,10 @@ interface PosMaster { fullNameCurrentHolder: string | null; fullNameNextHolder: string | null; positions: Position[]; // ตำแหน่ง + isSit: boolean; + profilePosition: string; + profilePostype: string; + profilePoslevel: string; } interface Position2 { id: string; // id ตำแหน่ง @@ -196,5 +200,4 @@ export type { HistoryPos, SelectPerson, TypePos, - }; diff --git a/src/modules/02_organizationalNew/store/organizational.ts b/src/modules/02_organizationalNew/store/organizational.ts index 47e68d018..096f392ca 100644 --- a/src/modules/02_organizationalNew/store/organizational.ts +++ b/src/modules/02_organizationalNew/store/organizational.ts @@ -79,11 +79,13 @@ export const useOrganizational = defineStore("organizationalStore", () => { e.posMasterNoPrefix + e.posMasterNo + e.posMasterNoSuffix, - positionName: e.positionName ? e.positionName : "-", - posTypeName: e.posTypeName ? e.posTypeName : "-", - posLevelName: e.posLevelName ? e.posLevelName : "-", - posExecutiveName: e.posExecutiveName ? e.posExecutiveName : "-", + positionName: e.isSit ? e.profilePosition : e.positionName, + posTypeName: e.isSit ? e.profilePostype : e.posTypeName, + posLevelName: e.isSit ? e.profilePoslevel : e.posLevelName, + posExecutiveName: e.posExecutiveName, + isSit: e.isSit, })); + return newPosMaster; }