From 6e321708c28112aa35e5ed73787a1014df7ac229 Mon Sep 17 00:00:00 2001 From: "DESKTOP-1R2VSQH\\Lenovo ThinkPad E490" Date: Mon, 30 Sep 2024 15:38:43 +0700 Subject: [PATCH] =?UTF-8?q?=E0=B8=9B=E0=B8=A3=E0=B8=B1=E0=B8=9A=E0=B9=81?= =?UTF-8?q?=E0=B8=AA=E0=B8=94=E0=B8=87=E0=B8=84=E0=B8=B3=E0=B8=AA=E0=B8=B1?= =?UTF-8?q?=E0=B9=88=E0=B8=87?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../18_command/components/Main/DialogFormCommand.vue | 7 +++++-- src/modules/18_command/interface/response/Main.ts | 1 + 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/src/modules/18_command/components/Main/DialogFormCommand.vue b/src/modules/18_command/components/Main/DialogFormCommand.vue index ef7f1c69e..2ed5152a0 100644 --- a/src/modules/18_command/components/Main/DialogFormCommand.vue +++ b/src/modules/18_command/components/Main/DialogFormCommand.vue @@ -35,8 +35,11 @@ async function fetchCommandType() { .get(config.API.commandType) .then(async (res) => { const data = await res.data.result; - listCommand.value = data; - commandOp.value = data; + listCommand.value = data.map((e: DataCommandType) => ({ + id: e.id, + name: e.subtitle ? `${e.name}(${e.subtitle})` : `${e.name}`, + })); + commandOp.value = listCommand.value; }) .catch((err) => { messageError($q, err); diff --git a/src/modules/18_command/interface/response/Main.ts b/src/modules/18_command/interface/response/Main.ts index 40c60bc25..87f915311 100644 --- a/src/modules/18_command/interface/response/Main.ts +++ b/src/modules/18_command/interface/response/Main.ts @@ -30,6 +30,7 @@ interface DataCommandType { lastUpdateUserId: string; lastUpdatedAt: string | Date; name: string; + subtitle: string; } interface DataFileDownload {