action: 'changePath',
before: 'beforeChangePath',
conditions : {
- ':path' : '(?:([%a-zA-Z0-9\-\_\s,]+))',
- ':subpath' : '(?:(?::)([%a-zA-Z0-9\-\_\s,]+))?'
+ ':path' : '(?:([%a-zA-Z0-9\\-\\_\\s,]+))',
+ ':subpath' : '(?:(?::)([%a-zA-Z0-9\\-\\_\\s,]+))?'
}
}
},
subpath = subpath || 0;
if (lastpanel.getActiveTab) {
// we assume lastpanel is a tabpanel
- if (lastpanel.getActiveTab().getItemId() === subpath) {
- // we are already there
- } else {
+ if (lastpanel.getActiveTab().getItemId() !== subpath) {
// set the active tab
lastpanel.setActiveTab(subpath);
}
+ // else we are already there
}
action.stop();
return;
},
logout: function() {
- var me = this;
- Proxmox.Utils.authClear();
- /*jslint confusion: true*/
- /*destroy is a function below and boolean above */
- me.getView().destroy();
- /*jslint confusion: false*/
- Ext.create({ xtype: 'loginview'});
+ PMG.app.logout();
},
navigate: function(treelist, item) {
interval: 15*60*1000
});
- var provider = new Ext.state.LocalStorageProvider({
- prefix: 'ext-pmg-' });
- Ext.state.Manager.setProvider(provider);
-
// select treeitem and load page from url fragment
var token = Ext.util.History.getToken() || 'pmgDashboard';
this.redirectTo(token, true);
type: 'hbox',
align: 'middle'
},
- margin: '4 5 4 5',
+ margin: '2 5 2 5',
+ height: 38,
items: [
{
xtype: 'proxmoxlogo'
baseCls: 'x-plain',
reference: 'usernameinfo',
padding: '0 5',
- tpl: Ext.String.format(gettext("You are logged in as '{0}'"), '{username}')
+ tpl: Ext.String.format(gettext("You are logged in as {0}"), "'{username}'")
},
{
xtype: 'proxmoxHelpButton',
hidden: false,
baseCls: 'x-btn',
iconCls: 'fa fa-info-circle x-btn-icon-el-default-toolbar-small ',
+ margin: '0 5 0 0',
listenToGlobalEvent: false,
onlineHelp: 'pmg_documentation_index'
},