remove setTimeout

This commit is contained in:
setthawutttty 2025-07-08 13:53:17 +07:00
parent 8a87f084c9
commit 8e28b14935
2 changed files with 5 additions and 15 deletions

View file

@ -20,9 +20,7 @@ async function onSubmit(data: any) {
.post(config.API.complaintAdd(), data) .post(config.API.complaintAdd(), data)
.then((res) => { .then((res) => {
success($q, "บันทึกข้อมูลสำเร็จ"); success($q, "บันทึกข้อมูลสำเร็จ");
setTimeout(() => { router.push(`/discipline/complaints/${res.data.result}`);
router.push(`/discipline/complaints/${res.data.result}`);
}, 1200);
}) })
.catch((e) => { .catch((e) => {
messageError($q, e); messageError($q, e);

View file

@ -335,18 +335,9 @@ onMounted(async () => {
showLoader(); showLoader();
await Promise.all([ await Promise.all([
fetchDataSigner(), fetchDataSigner(),
formTemplates.value.forEach((e) => { Promise.all(
downloadFileList(e.fileName); formTemplates.value.map((e) => downloadFileList(e.fileName))
}), ),
// downloadFileList(
// " ( )"
// ),
// downloadFileList("- ( 15)"),
// downloadFileList(" ( 16)"),
// downloadFileList(" ( 17)"),
// downloadFileList(" ( 18)"),
// downloadFileList(" ( )"),
checkDocEdit(), checkDocEdit(),
]); ]);
} catch (error) { } catch (error) {
@ -355,6 +346,7 @@ onMounted(async () => {
hideLoader(); hideLoader();
} }
}); });
</script> </script>
<template> <template>