mirror of
https://git.proxmox.com/git/pmg-gui
synced 2025-08-05 16:55:33 +00:00
let the default token be chosen by the view
instead of the application, since we want a different default token for the admin view and the quarantine view Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
This commit is contained in:
parent
fc7de588fd
commit
033228c06d
@ -3,9 +3,6 @@ Ext.define('PMG.Application', {
|
||||
|
||||
name: 'PMG',
|
||||
|
||||
// default fragment for the router
|
||||
defaultToken: 'pmgDashboard',
|
||||
|
||||
stores: [
|
||||
'NavigationStore'
|
||||
],
|
||||
|
@ -142,7 +142,7 @@ Ext.define('PMG.MainView', {
|
||||
});
|
||||
|
||||
// select treeitem and load page from url fragment
|
||||
var token = Ext.util.History.getToken();
|
||||
var token = Ext.util.History.getToken() || 'pmgDashboard';
|
||||
this.redirectTo(token, true);
|
||||
|
||||
}
|
||||
|
@ -179,8 +179,7 @@ Ext.define('PMG.QuarantineView', {
|
||||
me.execQuarantineAction(qa);
|
||||
} else {
|
||||
// select treeitem and load page from url fragment
|
||||
var token = Ext.util.History.getToken();
|
||||
if (!token || token === 'pmgDashboard') token = 'pmgSpamQuarantine'; // hack
|
||||
var token = Ext.util.History.getToken() || 'pmgSpamQuarantine';
|
||||
this.redirectTo(token, true);
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user