Skip to content

Commit

Permalink
Fix #462 Can't delete Categories and Subcategories event handling in …
Browse files Browse the repository at this point in the history
…deleteSubmit button
  • Loading branch information
navjottomer committed Apr 23, 2024
1 parent 0b4a2fa commit 06e4031
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion oc-admin/themes/modern/categories/index.php
Original file line number Diff line number Diff line change
Expand Up @@ -306,7 +306,9 @@ function delete_category(id) {
return false;
}

document.getElementById("deleteSubmit").onclick = function () {
document.getElementById("deleteSubmit").onclick = function (e) {
// prevent other events
e.preventDefault();
let categoryId = document.getElementById(
"deleteModal"
).dataset.categoryId;
Expand Down

0 comments on commit 06e4031

Please sign in to comment.