diff --git a/application/cmdbabstract.class.inc.php b/application/cmdbabstract.class.inc.php index bdff79a5f..798066e86 100644 --- a/application/cmdbabstract.class.inc.php +++ b/application/cmdbabstract.class.inc.php @@ -5137,8 +5137,8 @@ EOF $sJSTitle = json_encode(Dict::S('UI:DisconnectedDlgTitle')); $sJSOk = json_encode(Dict::S('UI:Button:Ok')); $oPage->add_ready_script( - <<'+data.message+''); - $('
'+data.popup_message+'
').dialog({title: $sJSTitle, modal: true, autoOpen: true, buttons:[ {text: $sJSOk, click: function() { $(this).dialog('close'); } }], close: function() { $(this).remove(); }}); + $('
'+data.popup_message+'
').dialog({title: $sJSTitle, modal: true, autoOpen: true, minWidth: 600, buttons:[ {text: $sJSOk, click: function() { $(this).dialog('close'); } }], close: function() { $(this).remove(); }}); } - $('.wizContainer form button.action:not(.cancel)').prop('disabled', true); + $('.object-details form .ibo-toolbar .ibo-button:not([name="cancel"])').prop('disabled', true); + clearInterval(hOwnershipLockHandlerInterval); } else if ((data.operation == 'lost') || (data.operation == 'expired')) { if ($('.lock_owned').length == 0) { $('.ui-layout-content').prepend('
'+data.message+'
'); - $('
'+data.popup_message+'
').dialog({title: $sJSTitle, modal: true, autoOpen: true, buttons:[ {text: $sJSOk, click: function() { $(this).dialog('close'); } }], close: function() { $(this).remove(); }}); + $('
'+data.popup_message+'
').dialog({title: $sJSTitle, modal: true, autoOpen: true, minWidth: 600, buttons:[ {text: $sJSOk, click: function() { $(this).dialog('close'); } }], close: function() { $(this).remove(); }}); } - $('.wizContainer form button.action:not(.cancel)').prop('disabled', true); + $('.object-details form .ibo-toolbar .ibo-button:not([name="cancel"])').prop('disabled', true); + clearInterval(hOwnershipLockHandlerInterval); } }, 'json'); }, $iInterval); -EOF +JS ); } diff --git a/pages/ajax.render.php b/pages/ajax.render.php index b66d7196f..90e8b01ce 100644 --- a/pages/ajax.render.php +++ b/pages/ajax.render.php @@ -2394,6 +2394,7 @@ EOF } } } + $oPage->SetContentType('application/json'); $oPage->add(json_encode($aResult)); break;