From ba90a6534eee1f03620342ed2d9c4551fb1f072c Mon Sep 17 00:00:00 2001 From: Methapon2001 <61303214+Methapon2001@users.noreply.github.com> Date: Thu, 8 Aug 2024 10:33:29 +0700 Subject: [PATCH] refactor: update customer form dialog --- src/pages/03_customer-management/MainPage.vue | 39 ++++++++++++------- 1 file changed, 24 insertions(+), 15 deletions(-) diff --git a/src/pages/03_customer-management/MainPage.vue b/src/pages/03_customer-management/MainPage.vue index 45db2671..98fbcf6e 100644 --- a/src/pages/03_customer-management/MainPage.vue +++ b/src/pages/03_customer-management/MainPage.vue @@ -52,6 +52,7 @@ import FormEmployeeOther from 'src/components/03_customer-management/FormEmploye import useOptionStore from 'src/stores/options'; import { DialogContainer, DialogHeader } from 'src/components/dialog'; + const { t, locale } = useI18n(); const $q = useQuasar(); const route = useRoute(); @@ -1787,20 +1788,28 @@ watch( >
{ - if ( - v && - customerFormState.dialogType === 'edit' && - customerFormState.editCustomerId - ) { + if (v && customerFormState.editCustomerId) { await customerStore.setImage(customerFormState.editCustomerId, v); await fetchListCustomer(); customerFormState.imageDialog = false;