crud with conditions

This commit is contained in:
null
2024-02-28 21:02:23 +01:00
parent 99b78c9bd1
commit a56cf12c2a
6 changed files with 82 additions and 35 deletions
+8 -1
View File
@@ -13,7 +13,14 @@ function documentReady() {
openDialog.close();
window.location.reload();
} else {
document.querySelector("dialog").showModal()
const dialog = document.querySelector("dialog")
if (iframe.contentWindow.location.href.split("/").pop() === "create") {
dialog.className = 'create';
} else {
dialog.className = 'update';
}
dialog.showModal()
}
}
}