Fix:Remove detail url when no item selected (#5055)

fixes #5053
This commit is contained in:
Johannes Meyer 2023-09-07 09:32:11 +02:00 committed by GitHub
commit 7c6c793ac3
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 5 additions and 4 deletions

View File

@ -1061,7 +1061,6 @@
if (req.addToHistory && ! req.autorefresh) {
req.$target.data('icingaRefresh', 0);
req.$target.data('icingaUrl', url);
icinga.history.pushCurrentState();
}
if (typeof req.progressTimer !== 'undefined') {
@ -1090,8 +1089,9 @@
req.$target
);
// Aborted requests should not be added to browser history
req.addToHistory = false;
if (req.scripted) {
req.addToHistory = false;
}
} else {
if (this.failureNotice === null) {
var now = new Date();

View File

@ -342,6 +342,7 @@
},
closeContainer: function($c) {
this.icinga.loader.stopPendingRequestsFor($c);
$c.removeData('icingaUrl');
$c.removeData('icingaTitle');
$c.removeData('icingaRefresh');
@ -349,8 +350,8 @@
$c.removeData('icingaModule');
delete $c[0].dataset.icingaContainerId;
$c.removeAttr('class').attr('class', 'container');
this.icinga.loader.stopPendingRequestsFor($c);
$c.trigger('close-column');
this.icinga.history.pushCurrentState();
$c.html('');
},