Refactor using delegated event [SCI-7745]

This commit is contained in:
sboursen-scinote 2023-01-19 15:36:34 +01:00
parent 3e60885d05
commit 658862fca7

View file

@ -230,12 +230,12 @@ var ExperimnetTable = {
return true;
};
$('#modal-edit-module').on('click', 'button[data-action="confirm"]', handleRenameModal);
$('#modal-edit-module').find('form').submit((e) => {
e.preventDefault();
handleRenameModal();
});
$('#modal-edit-module')
.on('click', 'button[data-action="confirm"]', handleRenameModal)
.on('submit', 'form', (e) => {
e.preventDefault();
handleRenameModal();
});
},
initManageUsersDropdown: function() {
$(this.table).on('show.bs.dropdown', '.assign-users-dropdown', (e) => {