fix redirect back spatial plannings

This commit is contained in:
arifal
2025-03-13 15:48:53 +07:00
parent 0258ca9f04
commit e97b7eb70d
7 changed files with 34 additions and 70 deletions

View File

@@ -28,6 +28,7 @@ console.log(dropzonePreviewNode);
.getAttribute("content")}`,
},
init: function () {
let menuId = document.getElementById("menuId").value;
// Listen for the success event
this.on("success", function (file, response) {
console.log("File successfully uploaded:", file);
@@ -39,7 +40,7 @@ console.log(dropzonePreviewNode);
"Upload Files";
// Tunggu sebentar lalu reload halaman
setTimeout(() => {
window.location.href = "/data/web-spatial-plannings";
window.location.href = `/data/web-spatial-plannings?menu_id=${menuId}`;
}, 2000);
});
// Listen for the error event