ทดลองงาน fix bug
This commit is contained in:
parent
c83df20a60
commit
f565dafb0a
2 changed files with 28 additions and 27 deletions
|
|
@ -258,26 +258,23 @@ const openModalTree = (data: any, type: string) => {
|
|||
posLevel.value = data.positionLevelOld;
|
||||
position.value = data.positionOld;
|
||||
};
|
||||
//เเจ้งเตือนลบข้อมูล
|
||||
//เบข้อมูล
|
||||
const clickDelete = (id: string) => {
|
||||
dialogRemove($q, () => deleteAppoint(id));
|
||||
};
|
||||
|
||||
// ลบข้อมูล
|
||||
const deleteAppoint = async (id: string) => {
|
||||
showLoader();
|
||||
await http
|
||||
.delete(config.API.appointmentDelete(id))
|
||||
.then(() => {
|
||||
success($q, "ลบข้อมูลสำเร็จ");
|
||||
})
|
||||
.catch((e) => {
|
||||
messageError($q, e);
|
||||
})
|
||||
.finally(() => {
|
||||
fecthlistappointment();
|
||||
hideLoader();
|
||||
});
|
||||
dialogRemove($q, () => {
|
||||
showLoader();
|
||||
http
|
||||
.delete(config.API.appointmentDelete(id))
|
||||
.then(() => {
|
||||
success($q, "ลบข้อมูลสำเร็จ");
|
||||
})
|
||||
.catch((e) => {
|
||||
messageError($q, e);
|
||||
})
|
||||
.finally(() => {
|
||||
fecthlistappointment();
|
||||
hideLoader();
|
||||
});
|
||||
});
|
||||
};
|
||||
|
||||
// ไปหน้ารายละเอียด
|
||||
|
|
@ -546,7 +543,7 @@ onMounted(() => {
|
|||
<q-item
|
||||
clickable
|
||||
v-close-popup
|
||||
@click="clickDelete(props.row.personalId)"
|
||||
@click="clickDelete(props.row.id)"
|
||||
>
|
||||
<q-item-section
|
||||
style="min-width: 0px"
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue