From f24c737c0be17b8a5e44f6355bbdec80539732cf Mon Sep 17 00:00:00 2001 From: setthawutttty Date: Fri, 19 Jan 2024 14:12:08 +0700 Subject: [PATCH] =?UTF-8?q?=E0=B9=81=E0=B8=81=E0=B9=89=20popup=20=E0=B8=A7?= =?UTF-8?q?=E0=B8=B4=E0=B8=99=E0=B8=B1=E0=B8=A2=20=E0=B8=81=E0=B8=A3?= =?UTF-8?q?=E0=B8=A3=E0=B8=A1=E0=B8=81=E0=B8=B2=E0=B8=A3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../11_discipline/components/DialogDuty.vue | 21 ++++++++----------- 1 file changed, 9 insertions(+), 12 deletions(-) diff --git a/src/modules/11_discipline/components/DialogDuty.vue b/src/modules/11_discipline/components/DialogDuty.vue index d93c10fc1..993f16f12 100644 --- a/src/modules/11_discipline/components/DialogDuty.vue +++ b/src/modules/11_discipline/components/DialogDuty.vue @@ -49,22 +49,19 @@ async function submit() { if (myForm.value !== null) { myForm.value.validate().then((success) => { if (success) { - dialogConfirm( - $q, - async () => { - await props.save(props.id, duty.value, resolution.value); - duty.value = ""; - resolution.value = ""; - } - ); + dialogConfirm($q, async () => { + await props.save(props.id, duty.value, resolution.value); + duty.value = ""; + resolution.value = ""; + }); } }); } } watch(props, () => { - duty.value = props?.duty; - resolution.value = props?.command; + duty.value = props?.duty === "-" ? "" : props.duty; + resolution.value = props?.command === "-" ? "" : props.command; }); @@ -81,7 +78,7 @@ watch(props, () => { dense class="col-12 q-mb-sm" debounce="300" - placeholder="หน้าที่" + label="หน้าที่" :rules="[(val) => !!val || `กรุณากรอกหน้าที่`]" hide-bottom-space /> @@ -91,7 +88,7 @@ watch(props, () => { dense class="col-12 q-mb-sm" debounce="300" - placeholder="มติ/คำสั่ง" + label="มติ/คำสั่ง" :rules="[(val) => !!val || `กรุณากรอก มติ/คำสั่ง`]" hide-bottom-space />