diff --git a/Netdisco/share/views/ajax/device/details.tt b/Netdisco/share/views/ajax/device/details.tt index 47c42ed8..0959b430 100644 --- a/Netdisco/share/views/ajax/device/details.tt +++ b/Netdisco/share/views/ajax/device/details.tt @@ -98,30 +98,33 @@ Admin Tasks - - - - - - + + + + + + - - diff --git a/Netdisco/share/views/js/device.js b/Netdisco/share/views/js/device.js index 0e755df9..eee0cad2 100644 --- a/Netdisco/share/views/js/device.js +++ b/Netdisco/share/views/js/device.js @@ -27,7 +27,8 @@ $('#nd_netmap-help').hide(); } - // activate tooltips and popovers + // activate modals, tooltips and popovers + $('.nd_modal').modal({show: false}); $("[rel=tooltip]").tooltip({live: true}); $("[rel=popover]").popover({live: true}); } @@ -37,7 +38,7 @@ var tab = '[% tab.tag %]' var target = '#' + tab + '_pane'; - // sidebar form fields should change colour and have bin/copy icon + // sidebar form fields should change colour and have trash/copy icon form_inputs.each(function() {device_form_state($(this))}); form_inputs.change(function() {device_form_state($(this))}); @@ -52,7 +53,7 @@ .toggleClass('icon-chevron-up icon-chevron-down'); }); - // handler for bin icon in port filter box + // handler for trashcan icon in port filter box var portfilter = $('#ports_form').find("input[name=f]"); $('.nd_field-clear-icon').click(function() { portfilter.val(''); @@ -86,8 +87,6 @@ } }); - $('#deleteConfirm').modal(); - // activity for admin tasks in device details $('#details_pane').on('click', '.nd_adminbutton', function(event) { // stop form from submitting normally @@ -103,7 +102,7 @@ ,async: true ,dataType: 'html' ,url: uri_base + '/ajax/control/admin/' + mode - ,data: tr.find('input[data-form="' + mode + '"]').serializeArray() + ,data: tr.find('input[data-form="' + mode + '"],textarea[data-form="' + mode + '"]').serializeArray() ,success: function() { toastr.info('Queued '+ mode +' for device '+ tr.attr('data-for-device')); }