This commit is contained in:
DESKTOP-1R2VSQH\Lenovo ThinkPad E490 2024-07-03 16:20:20 +07:00
parent 5785ae6418
commit ca213d6c76

View file

@ -175,18 +175,21 @@ function closeDialog() {
}
/** dialog submit */
function onSubmit() {
async function onSubmit() {
if (formProject.nodeId) {
http
await showLoader();
await http
.post(config.API.developmentMain, formProject)
.then((res) => {
closeDialog();
router.push(`/development/${res.data.result}`);
})
.catch((e) => {
messageError($q, e);
})
.finally(() => {});
.finally(async () => {
await closeDialog();
await hideLoader();
});
} else {
dialogMessageNotify($q, "กรุณาเลือกหน่วยงานที่รับผิดชอบ");
}