From ecc9ab9a4c6bd4d858ba3e45dee10cb3bbfc591f Mon Sep 17 00:00:00 2001 From: "DESKTOP-1R2VSQH\\Lenovo ThinkPad E490" Date: Mon, 1 Sep 2025 10:52:43 +0700 Subject: [PATCH] =?UTF-8?q?fix=20=3D=3D>=20=E0=B9=82=E0=B8=84=E0=B8=A3?= =?UTF-8?q?=E0=B8=87=E0=B8=AA=E0=B8=A3=E0=B9=89=E0=B8=B2=E0=B8=87=E0=B8=AD?= =?UTF-8?q?=E0=B8=B1=E0=B8=95=E0=B8=A3=E0=B8=B2=E0=B8=81=E0=B8=B3=E0=B8=A5?= =?UTF-8?q?=E0=B8=B1=E0=B8=87=20=E0=B8=9B=E0=B8=A3=E0=B8=B0=E0=B8=A7?= =?UTF-8?q?=E0=B8=B1=E0=B8=95=E0=B8=B4=E0=B8=84=E0=B8=99=E0=B8=84=E0=B8=A3?= =?UTF-8?q?=E0=B8=AD=E0=B8=87?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../components/DialogHistoryPos.vue | 16 ++++++++- .../02_organization/components/TableMain.vue | 34 +++++++++++++++++++ 2 files changed, 49 insertions(+), 1 deletion(-) diff --git a/src/modules/02_organization/components/DialogHistoryPos.vue b/src/modules/02_organization/components/DialogHistoryPos.vue index 530597dfa..6e6b1de07 100644 --- a/src/modules/02_organization/components/DialogHistoryPos.vue +++ b/src/modules/02_organization/components/DialogHistoryPos.vue @@ -191,7 +191,17 @@ async function fetchHistoryPos(id: string) { .get(pathAPI) .then((res) => { const data = res.data.result; - rows.value = data; + rows.value = + props.historyType === "HISTORY" + ? data + : data.map((e: any) => ({ + ...e, + fullname: + e.prefix && e.firstName && e.lastName + ? `${e.prefix ?? ""} ${e.firstName ?? ""} ${e.lastName ?? ""}` + : "-", + shortName: e.orgShortName, + })); }) .catch((err) => { messageError($q, err); @@ -206,6 +216,10 @@ watch( () => modal.value, () => { modal.value && props.rowId && fetchHistoryPos(props.rowId); + + if (!modal.value) { + rows.value = []; + } } ); diff --git a/src/modules/02_organization/components/TableMain.vue b/src/modules/02_organization/components/TableMain.vue index f54a78f80..031840028 100644 --- a/src/modules/02_organization/components/TableMain.vue +++ b/src/modules/02_organization/components/TableMain.vue @@ -859,6 +859,40 @@ watch( + + + + + +
+ +
{{ item.label }}
+
+
+
+
+
+
+