From 8ad8e9354a742bdb8882546dd986e6afda006a0f Mon Sep 17 00:00:00 2001 From: setthawutttty Date: Thu, 23 Jan 2025 11:12:35 +0700 Subject: [PATCH] =?UTF-8?q?=E0=B9=81=E0=B8=81=E0=B9=89=20=E0=B8=9F?= =?UTF-8?q?=E0=B8=B4=E0=B8=A5=E0=B9=80=E0=B8=95=E0=B8=AD=E0=B8=A3=E0=B9=8C?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../10_registry/04_Achievement/03_Insignia.vue | 15 ++++++++++++++- src/modules/10_registry/Dialog/DialogHistory.vue | 1 + 2 files changed, 15 insertions(+), 1 deletion(-) diff --git a/src/modules/10_registry/04_Achievement/03_Insignia.vue b/src/modules/10_registry/04_Achievement/03_Insignia.vue index 2f6984e..5a8d4fc 100644 --- a/src/modules/10_registry/04_Achievement/03_Insignia.vue +++ b/src/modules/10_registry/04_Achievement/03_Insignia.vue @@ -23,7 +23,8 @@ const rowsHistoryData = ref([]); const $q = useQuasar(); const mode = ref($q.screen.gt.xs); const mixin = useCounterMixin(); -const { showLoader, hideLoader, messageError, date2Thai,onSearchDataTable } = mixin; +const { showLoader, hideLoader, messageError, date2Thai, onSearchDataTable } = + mixin; const modalHistory = ref(false); /** ตัวแปรข้อมูล */ @@ -78,6 +79,9 @@ const columns = ref([ field: "insigniaId", headerStyle: "font-size: 14px", style: "font-size: 14px", + format: (val, row) => { + return `${row.insignia.name} (${row.insignia.shortName})`; + }, sort: (a: string, b: string) => a.localeCompare(b, undefined, { numeric: true, sensitivity: "base" }), }, @@ -87,6 +91,9 @@ const columns = ref([ label: "ลำดับชั้น", sortable: true, field: (v) => v.insignia.insigniaType.name, + format: (val, row) => { + return `${row.insignia.insigniaType.name}`; + }, headerStyle: "font-size: 14px", style: "font-size: 14px", sort: (a: string, b: string) => @@ -278,6 +285,9 @@ const columnsHistory = ref([ field: "insigniaId", headerStyle: "font-size: 14px", style: "font-size: 14px", + format: (val, row) => { + return `${row.insignia.name} (${row.insignia.shortName})`; + }, sort: (a: string, b: string) => a.localeCompare(b, undefined, { numeric: true, sensitivity: "base" }), }, @@ -287,6 +297,9 @@ const columnsHistory = ref([ label: "ลำดับชั้น", sortable: true, field: (v) => v.insignia.insigniaType.name, + format: (val, row) => { + return `${row.insignia.insigniaType.name}`; + }, headerStyle: "font-size: 14px", style: "font-size: 14px", sort: (a: string, b: string) => diff --git a/src/modules/10_registry/Dialog/DialogHistory.vue b/src/modules/10_registry/Dialog/DialogHistory.vue index 79d3222..f7e76fe 100644 --- a/src/modules/10_registry/Dialog/DialogHistory.vue +++ b/src/modules/10_registry/Dialog/DialogHistory.vue @@ -24,6 +24,7 @@ const props = defineProps({ }); function close() { modal.value = false; + filter.value = '' } function dateThaiRange(val: [Date, Date]) {