Move subfleet add/remove to fleet service for a flight

This commit is contained in:
Nabeel Shahzad
2018-03-23 14:10:18 -05:00
parent 1161106d9c
commit f8f5a71564
5 changed files with 61 additions and 2 deletions

View File

@@ -63,6 +63,14 @@ $(document).ready(function () {
setEditable();
setFieldsEditable();
/*const pjax = new Pjax({
elements: 'form[action]',
selectors: ['.pjax_subfleet_form'],
switches: {
'#subfleet_flight_wrapper': Pjax.switches.replaceNode
}
});*/
$(document).on('submit', 'form.pjax_flight_fields', function (event) {
event.preventDefault();
$.pjax.submit(event, '#flight_fields_wrapper', {push: false});