แสดงข้อมูล ปฏิทินวันทำงาน

This commit is contained in:
DESKTOP-1R2VSQH\Lenovo ThinkPad E490 2024-01-10 11:04:27 +07:00
parent 507763bbbf
commit 0ae36dcccb

View file

@ -56,11 +56,30 @@ function Openmodal(check: string, detail: any) {
}
}
/**
* function เรยกขอมลปฏนวนทำงาน
* @param id profileId
*/
async function fetchDataCalendarWork(id: string) {
showLoader();
await http
.get(config.API.leaveWorkByid(id))
.then((res) => {
dateWork.value = res.data.result.work;
})
.catch((err) => {
messageError($q, err);
})
.finally(() => {
modalFix.value = true;
hideLoader();
});
}
const detailByid = ref();
function OpenmodalFix(detail: any) {
dateWork.value = "NORMAL";
async function OpenmodalFix(detail: any) {
await fetchDataCalendarWork(detail.profileId);
detailByid.value = detail;
modalFix.value = true;
}
/** Function closePopup */