new loader
This commit is contained in:
parent
fd7aae2f5d
commit
fe6c712a18
95 changed files with 1189 additions and 950 deletions
|
|
@ -129,7 +129,7 @@ const pass = ref<number>(0);
|
|||
const notpass = ref<number>(0);
|
||||
const importId = ref<string>(route.params.id as string); // Period Import Id
|
||||
const mixin = useCounterMixin();
|
||||
const { messageError } = mixin;
|
||||
const { messageError, showLoader, hideLoader } = mixin;
|
||||
const filter = ref<string>(""); //search data table
|
||||
const visibleColumns = ref<String[]>([
|
||||
"examID",
|
||||
|
|
@ -317,12 +317,12 @@ const clickDetail = (examID: string) => {
|
|||
};
|
||||
|
||||
onMounted(async () => {
|
||||
loaderPage(false);
|
||||
hideLoader();
|
||||
await fetchData();
|
||||
});
|
||||
|
||||
const downloadExam = async () => {
|
||||
loaderPage(true);
|
||||
showLoader();
|
||||
await http
|
||||
.get(config.API.exportDisableExam(importId.value), {
|
||||
responseType: "blob",
|
||||
|
|
@ -338,12 +338,12 @@ const downloadExam = async () => {
|
|||
messageError($q, e);
|
||||
})
|
||||
.finally(() => {
|
||||
loaderPage(false);
|
||||
hideLoader();
|
||||
});
|
||||
};
|
||||
|
||||
const downloadPassExam = async () => {
|
||||
loaderPage(true);
|
||||
showLoader();
|
||||
await http
|
||||
.get(config.API.exportDisablePassExam(importId.value), {
|
||||
responseType: "blob",
|
||||
|
|
@ -359,12 +359,12 @@ const downloadPassExam = async () => {
|
|||
messageError($q, e);
|
||||
})
|
||||
.finally(() => {
|
||||
loaderPage(false);
|
||||
hideLoader();
|
||||
});
|
||||
};
|
||||
|
||||
const downloadPassResultExam = async () => {
|
||||
loaderPage(true);
|
||||
showLoader();
|
||||
await http
|
||||
.get(config.API.exportDisablePassResultExam(importId.value), {
|
||||
responseType: "blob",
|
||||
|
|
@ -380,12 +380,12 @@ const downloadPassResultExam = async () => {
|
|||
messageError($q, e);
|
||||
})
|
||||
.finally(() => {
|
||||
loaderPage(false);
|
||||
hideLoader();
|
||||
});
|
||||
};
|
||||
|
||||
const fetchData = async () => {
|
||||
loaderPage(true);
|
||||
showLoader();
|
||||
await http
|
||||
.post(config.API.getDisableExamResultById(importId.value), {
|
||||
examAttribute: "",
|
||||
|
|
@ -416,7 +416,7 @@ const fetchData = async () => {
|
|||
messageError($q, e);
|
||||
})
|
||||
.finally(() => {
|
||||
loaderPage(false);
|
||||
hideLoader();
|
||||
});
|
||||
};
|
||||
</script>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue