]> git.proxmox.com Git - proxmox-backup.git/blobdiff - www/MainView.js
buildsys: fix targets to not run dpkg-buildpackage 4 times
[proxmox-backup.git] / www / MainView.js
index 0ce7e451f577028ad0e7d76355c0e8207c5b3054..c5764b1febf7d3eb969f0afb22a07e004dc0ad18 100644 (file)
@@ -72,10 +72,15 @@ Ext.define('PBS.MainView', {
                let datastore = PBS.Utils.getDataStoreFromPath(path);
                obj = contentpanel.add({
                    xtype: 'pbsDataStorePanel',
+                   nodename: 'localhost',
                    datastore,
                });
            } else {
-               obj = contentpanel.add({ xtype: path, border: false });
+               obj = contentpanel.add({
+                   xtype: path,
+                   nodename: 'localhost',
+                   border: false
+               });
            }
 
            var treelist = me.lookupReference('navtree');
@@ -120,7 +125,7 @@ Ext.define('PBS.MainView', {
        },
 
        control: {
-           'button[reference=logoutButton]': {
+           '[reference=logoutButton]': {
                click: 'logout'
            }
        },
@@ -128,7 +133,8 @@ Ext.define('PBS.MainView', {
        init: function(view) {
            var me = this;
 
-           me.lookupReference('usernameinfo').update({username:Proxmox.UserName});
+           PBS.data.RunningTasksStore.startUpdate();
+           me.lookupReference('usernameinfo').setText(Proxmox.UserName);
 
            // show login on requestexception
            // fixme: what about other errors
@@ -184,7 +190,7 @@ Ext.define('PBS.MainView', {
                type: 'hbox',
                align: 'middle'
            },
-           margin: '2 5 2 5',
+           margin: '2 0 2 5',
            height: 38,
            items: [
                {
@@ -192,16 +198,17 @@ Ext.define('PBS.MainView', {
                    prefix: '',
                },
                {
-                   xtype: 'versioninfo'
+                   padding: '0 0 0 5',
+                   xtype: 'versioninfo',
                },
                {
-                   flex: 1
+                   padding: 5,
+                   html: '<a href="https://bugzilla.proxmox.com" target="_blank">BETA</a>',
+                   baseCls: 'x-plain',
                },
                {
+                   flex: 1,
                    baseCls: 'x-plain',
-                   reference: 'usernameinfo',
-                   padding: '0 5',
-                   tpl: Ext.String.format(gettext("You are logged in as {0}"), "'{username}'")
                },
                {
                    xtype: 'button',
@@ -213,11 +220,27 @@ Ext.define('PBS.MainView', {
                    margin: '0 5 0 0',
                },
                {
-                   reference: 'logoutButton',
+                   xtype: 'pbsTaskButton',
+                   margin: '0 5 0 0',
+               },
+               {
                    xtype: 'button',
-                   iconCls: 'fa fa-sign-out',
-                   text: gettext('Logout')
-               }
+                   reference: 'usernameinfo',
+                   style: {
+                       // proxmox dark grey p light grey as border
+                       backgroundColor: '#464d4d',
+                       borderColor: '#ABBABA'
+                   },
+                   margin: '0 5 0 0',
+                   iconCls: 'fa fa-user',
+                   menu: [
+                       {
+                           reference: 'logoutButton',
+                           iconCls: 'fa fa-sign-out',
+                           text: gettext('Logout'),
+                       },
+                   ],
+               },
            ]
        },
        {