From fd2a76ecab41675e459a158c86c65fd3a2604e1c Mon Sep 17 00:00:00 2001 From: "DESKTOP-1R2VSQH\\Lenovo ThinkPad E490" Date: Thu, 24 Aug 2023 17:01:21 +0700 Subject: [PATCH] no message --- .../components/3_result/DialogForm.vue | 44 ++++++++++--------- src/modules/07_insignia/views/ResultPage.vue | 26 ++++++----- 2 files changed, 37 insertions(+), 33 deletions(-) diff --git a/src/modules/07_insignia/components/3_result/DialogForm.vue b/src/modules/07_insignia/components/3_result/DialogForm.vue index 19d5ef746..60fa7e5d0 100644 --- a/src/modules/07_insignia/components/3_result/DialogForm.vue +++ b/src/modules/07_insignia/components/3_result/DialogForm.vue @@ -47,7 +47,7 @@ const invoiceDate = ref(null); const employeeClass = ref(""); const employeeClassOps = ref([ { id: "officer", name: "ข้าราชการ กทม.สามัญ" }, - { id: "perm", name: "ลูกจ้างประจำ" }, + { id: "employee", name: "ลูกจ้างประจำ" }, ]); const listPerson = ref([]); @@ -120,6 +120,9 @@ const props = defineProps({ personId: { type: String, }, + profileType: { + type: String, + }, }); watch(props, () => { if (props.modal === true) { @@ -191,7 +194,7 @@ const findlist = async (id: string) => { let data = [{}]; if (employeeClass.value === "officer") { data = [{ criteriaType: "is_retire", criteriaValue: "false" }]; - } else if (employeeClass.value === "perm") { + } else if (employeeClass.value === "employee") { data = [ { criteriaType: "is_retire", criteriaValue: "false" }, { criteriaType: "employee_class", criteriaValue: "perm" }, @@ -202,7 +205,7 @@ const findlist = async (id: string) => { criterias: data, }) .then((res) => { - console.log(res.data.result); + // console.log(res.data.result); listPerson.value = res.data.result; }) .catch((e) => { @@ -217,7 +220,6 @@ const fectDataByid = async (id: string) => { await http .get(config.API.noteByid(id)) .then((res) => { - console.log(res); let data = res.data.result; employeeClass.value = ""; cardid.value = data.citizenId; @@ -238,9 +240,11 @@ const fectDataByid = async (id: string) => { payment.value = data.typePayment; addressPayment.value = data.address; status.value = data.status; + employeeClass.value = props.profileType; }) .catch((err) => { console.log(err); + messageError($q, err); }) .finally(() => { hideLoader(); @@ -267,7 +271,6 @@ const clickSave = async () => { }; await myForm.value!.validate().then((result: boolean) => { if (result) { - console.log(123); dialogConfirm($q, async () => { await addNote(body); }); @@ -295,7 +298,6 @@ const searchcardid = () => { fullName.value = data.fullname; position.value = data.positionEmployeePosition; } else notifyError($q, "ไม่พบข้อมูลเลขบัตรประชาชนนี้"); - console.log(data); } }; @@ -345,7 +347,7 @@ const searchcardid = () => {
{
--> {