fix bug
This commit is contained in:
parent
853a78f139
commit
1915538e5e
1 changed files with 17 additions and 21 deletions
|
|
@ -186,9 +186,9 @@ const calRetire = async (birth: Date) => {
|
||||||
dateBefore.value = birth;
|
dateBefore.value = birth;
|
||||||
})
|
})
|
||||||
.catch((e: any) => {
|
.catch((e: any) => {
|
||||||
messageError($q, e);
|
messageError($q, e);
|
||||||
informaData.value.birthDate = null;
|
informaData.value.birthDate = null;
|
||||||
informaData.value.age = "";
|
informaData.value.age = "";
|
||||||
})
|
})
|
||||||
.finally(() => {
|
.finally(() => {
|
||||||
// hideLoader();
|
// hideLoader();
|
||||||
|
|
@ -244,24 +244,20 @@ const addData = async () => {
|
||||||
if (informaData.value.employeeClass != undefined)
|
if (informaData.value.employeeClass != undefined)
|
||||||
formData.append("employeeClass", informaData.value.employeeClass);
|
formData.append("employeeClass", informaData.value.employeeClass);
|
||||||
|
|
||||||
console.log("informaData===>", informaData.value);
|
showLoader();
|
||||||
// showLoader();
|
await http
|
||||||
// await http
|
.post(config.API.createProfileOfficer(), formData)
|
||||||
// .post(config.API.createProfileOfficer(), formData)
|
.then((res) => {
|
||||||
// .then((res) => {
|
success($q, "บันทึกข้อมูลสำเร็จ");
|
||||||
// success($q, "บันทึกข้อมูลสำเร็จ");
|
})
|
||||||
// })
|
.catch((e) => {
|
||||||
// .catch((e) => {
|
messageError($q, e);
|
||||||
// messageError($q, e);
|
})
|
||||||
// })
|
.finally(async () => {
|
||||||
// .finally(async () => {
|
modal.value = false;
|
||||||
// modal.value = false;
|
await changeBirth(new Date(informaData.value.birthDate) ?? new Date());
|
||||||
// await changeBirth(
|
hideLoader();
|
||||||
// new Date(dateToPost(new Date(informaData.value.birthDate))) ??
|
});
|
||||||
// new Date()
|
|
||||||
// );
|
|
||||||
// hideLoader();
|
|
||||||
// });
|
|
||||||
};
|
};
|
||||||
|
|
||||||
/*** get รายการข้อมูลเกี่ยวกับบุคคล (dropdown list) */
|
/*** get รายการข้อมูลเกี่ยวกับบุคคล (dropdown list) */
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue