fix bug ลา
This commit is contained in:
parent
cf36f1c150
commit
e726510691
3 changed files with 42 additions and 48 deletions
|
|
@ -17,7 +17,7 @@ import type {
|
|||
} from "@/modules/05_leave/interface/response/leave";
|
||||
|
||||
const mixin = useCounterMixin();
|
||||
const { date2Thai, messageError } = mixin;
|
||||
const { date2Thai, messageError, showLoader, hideLoader } = mixin;
|
||||
const $q = useQuasar();
|
||||
const type = ref<string>("00000000-0000-0000-0000-000000000000");
|
||||
const status = ref<string>("ALL");
|
||||
|
|
@ -283,6 +283,7 @@ export const useLeaveStore = defineStore("Leave", () => {
|
|||
|
||||
//ดึงข้อมูล profile จาก API
|
||||
async function fetchProfile() {
|
||||
showLoader();
|
||||
await http
|
||||
.post(config.API.leaveProfile(), { type: typeId.value })
|
||||
.then((res: any) => {
|
||||
|
|
@ -311,6 +312,9 @@ export const useLeaveStore = defineStore("Leave", () => {
|
|||
})
|
||||
.catch((e: any) => {
|
||||
messageError($q, e);
|
||||
})
|
||||
.finally(() => {
|
||||
hideLoader();
|
||||
});
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue