From dd7ba98e6e83ab318a51dbd677504746059b4f28 Mon Sep 17 00:00:00 2001 From: waruneeta Date: Thu, 21 Sep 2023 11:16:23 +0700 Subject: [PATCH] =?UTF-8?q?fix=20bug=20popup=20=E0=B9=81=E0=B8=AA=E0=B8=94?= =?UTF-8?q?=E0=B8=87=E0=B8=8B=E0=B9=89=E0=B8=AD=E0=B8=99?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../08_registryEmployee/components/AddEmployee/Main.vue | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/src/modules/08_registryEmployee/components/AddEmployee/Main.vue b/src/modules/08_registryEmployee/components/AddEmployee/Main.vue index 7e8a5d4b7..35098cfc7 100644 --- a/src/modules/08_registryEmployee/components/AddEmployee/Main.vue +++ b/src/modules/08_registryEmployee/components/AddEmployee/Main.vue @@ -256,11 +256,6 @@ const calculateMaxDate = () => { }; // เช็คเรื่องการเกษียณ -const handleDate = async (modelData: Date) => { - informaData.value.birthDate = modelData; - await calRetire(modelData); -}; - const calRetire = async (birth: Date) => { const body = { birthDate: dateToISO(birth), @@ -272,6 +267,7 @@ const calRetire = async (birth: Date) => { .then((res: any) => { const data = res.data.result; informaData.value.age = data.age; + informaData.value.birthDate = birth; changeRetireText(data.retireDate); dateBefore.value = birth; }) @@ -390,7 +386,7 @@ const clickBack = () => {
+ :max-date="calculateMaxDate()" @update:model-value="calRetire">