mirror of
https://github.com/Combodo/iTop.git
synced 2026-05-21 16:22:20 +02:00
N°3817 - Audit and fix calls to deprecated jQuery method
This commit is contained in:
@@ -31,7 +31,7 @@ $.fn.modal.Constructor.prototype.enforceFocus = function () {
|
||||
var $parent = $(e.target.parentNode);
|
||||
if ($modalElement[0] !== e.target && !$modalElement.has(e.target).length &&
|
||||
!$parent.hasClass('ck-input')) {
|
||||
$(e.target.activeElement).focus();
|
||||
$(e.target.activeElement).trigger('focus');
|
||||
}
|
||||
})
|
||||
};
|
||||
|
||||
@@ -440,7 +440,7 @@ $(function()
|
||||
window.close();
|
||||
|
||||
// In some browser (eg. Firefox 70), window won't close if it has NOT been open by JS. In that case, we try to redirect to homepage as a fallback.
|
||||
var sHomepageUrl = (this.options.base_url !== null) ? this.options.base_url : $('#sidebar .menu .brick_menu_item:first a').attr('href')
|
||||
var sHomepageUrl = (this.options.base_url !== null) ? this.options.base_url : $('#sidebar .menu .brick_menu_item').first().find('a').attr('href')
|
||||
window.location.href = sHomepageUrl;
|
||||
}
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user