+ style: {
+ // proxmox dark grey p light grey as border
+ backgroundColor: '#464d4d',
+ borderColor: '#ABBABA',
+ },
+ iconCls: 'fa fa-user',
+ menu: [
+ {
+ iconCls: 'fa fa-gear',
+ text: gettext('My Settings'),
+ handler: function() {
+ var win = Ext.create('PVE.window.Settings');
+ win.show();
+ },
+ },
+ {
+ text: gettext('Password'),
+ itemId: 'passworditem',
+ iconCls: 'fa fa-fw fa-key',
+ handler: function() {
+ var win = Ext.create('Proxmox.window.PasswordEdit', {
+ userid: Proxmox.UserName,
+ confirmCurrentPassword: Proxmox.UserName !== 'root@pam',
+ });
+ win.show();
+ },
+ },
+ {
+ text: 'TFA',
+ itemId: 'tfaitem',
+ iconCls: 'fa fa-fw fa-lock',
+ handler: function(btn, event, rec) {
+ Ext.state.Manager.getProvider().set('dctab', { value: 'tfa' }, true);
+ me.selectById('root');
+ },
+ },
+ {
+ iconCls: 'fa fa-paint-brush',
+ text: gettext('Color Theme'),
+ handler: function() {
+ Ext.create('Proxmox.window.ThemeEditWindow')
+ .show();
+ },
+ },
+ {
+ iconCls: 'fa fa-language',
+ text: gettext('Language'),
+ handler: function() {
+ Ext.create('Proxmox.window.LanguageEditWindow')
+ .show();
+ },
+ },
+ '-',
+ {
+ iconCls: 'fa fa-fw fa-sign-out',
+ text: gettext("Logout"),
+ handler: function() {
+ PVE.data.ResourceStore.loadData([], false);
+ me.showLogin();
+ me.setContent(null);
+ var rt = me.down('pveResourceTree');
+ rt.setDatacenterText(undefined);
+ rt.clearTree();
+
+ // empty the stores of the StatusPanel child items
+ var statusPanels = Ext.ComponentQuery.query('pveStatusPanel grid');
+ Ext.Array.forEach(statusPanels, function(comp) {
+ if (comp.getStore()) {
+ comp.getStore().loadData([], false);
+ }
+ });
+ },
+ },
+ ],
+ },
+ ],