events.js: Trigger a real submit upon autosubmit
This commit is contained in:
parent
7da5eb0972
commit
cb6a0c120f
|
@ -183,7 +183,17 @@
|
|||
},
|
||||
|
||||
autoSubmitForm: function (event) {
|
||||
return event.data.self.submitForm(event, $(event.currentTarget));
|
||||
let form = event.currentTarget.form;
|
||||
|
||||
if (form.closest('[data-no-icinga-ajax]')) {
|
||||
return;
|
||||
}
|
||||
|
||||
form.dispatchEvent(new CustomEvent('submit', {
|
||||
cancelable: true,
|
||||
bubbles: true,
|
||||
detail: { submittedBy: event.currentTarget }
|
||||
}));
|
||||
},
|
||||
|
||||
/**
|
||||
|
|
Loading…
Reference in New Issue