mirror of
https://github.com/Icinga/icingaweb2.git
synced 2025-07-29 00:34:03 +02:00
loader.js: Perform a proper redirect upon __CLOSE__
This allows the temporary adjustment of the autorefresh interval.
This commit is contained in:
parent
03f62887b8
commit
8f5b62f532
@ -492,6 +492,7 @@
|
|||||||
*/
|
*/
|
||||||
processRedirectHeader: function(req) {
|
processRedirectHeader: function(req) {
|
||||||
var icinga = this.icinga,
|
var icinga = this.icinga,
|
||||||
|
$redirectTarget = req.$redirectTarget,
|
||||||
redirect = req.getResponseHeader('X-Icinga-Redirect');
|
redirect = req.getResponseHeader('X-Icinga-Redirect');
|
||||||
|
|
||||||
if (! redirect) {
|
if (! redirect) {
|
||||||
@ -594,14 +595,8 @@
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
// Refresh left column and produce a new history state for it
|
$redirectTarget = $('#col1');
|
||||||
let $refreshTarget = $('#col1');
|
redirect = icinga.history.getCol1State();
|
||||||
let refreshUrl = icinga.history.getCol1State();
|
|
||||||
let refresh = this.loadUrl(refreshUrl, $refreshTarget);
|
|
||||||
refresh.addToHistory = true;
|
|
||||||
refresh.scripted = true;
|
|
||||||
|
|
||||||
return true;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
var useHttp = req.getResponseHeader('X-Icinga-Redirect-Http');
|
var useHttp = req.getResponseHeader('X-Icinga-Redirect-Http');
|
||||||
@ -610,7 +605,7 @@
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
this.redirectToUrl(redirect, req.$redirectTarget, req);
|
this.redirectToUrl(redirect, $redirectTarget, req);
|
||||||
return true;
|
return true;
|
||||||
},
|
},
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user