]>
Commit | Line | Data |
---|---|---|
252645ce DM |
1 | Ext.define('PMG.ServerAdministration', { |
2 | extend: 'Ext.tab.Panel', | |
3 | alias: 'widget.pmgServerAdministration', | |
4 | ||
5 | title: gettext('Server Administration'), | |
6 | ||
830e5827 DM |
7 | border: false, |
8 | defaults: { border: false }, | |
9 | ||
cea4e924 DM |
10 | controller: { |
11 | xclass: 'Ext.app.ViewController', | |
12 | ||
13 | init: function(view) { | |
14 | var upgradeBtn = view.lookupReference('upgradeBtn'); | |
15 | upgradeBtn.setDisabled(!(Proxmox.UserName && Proxmox.UserName === 'root@pam')); | |
c87d46fb | 16 | }, |
cea4e924 DM |
17 | }, |
18 | ||
252645ce | 19 | items: [ |
e653eb82 | 20 | { |
61415efa | 21 | xtype: 'pmgServerStatus', |
c87d46fb | 22 | itemId: 'status', |
e653eb82 | 23 | }, |
252645ce | 24 | { |
0f3d85d5 | 25 | xtype: 'proxmoxNodeServiceView', |
252645ce | 26 | title: gettext('Services'), |
61415efa | 27 | itemId: 'services', |
0f3d85d5 DM |
28 | startOnlyServices: { |
29 | syslog: true, | |
30 | pmgproxy: true, | |
c87d46fb | 31 | pmgdaemon: true, |
0f3d85d5 | 32 | }, |
c87d46fb | 33 | nodename: Proxmox.NodeName, |
252645ce DM |
34 | }, |
35 | { | |
81c250bd | 36 | xtype: 'proxmoxNodeAPT', |
252645ce | 37 | title: gettext('Updates'), |
81c250bd DM |
38 | upgradeBtn: { |
39 | xtype: 'button', | |
cea4e924 DM |
40 | reference: 'upgradeBtn', |
41 | disabled: true, | |
81c250bd DM |
42 | text: gettext('Upgrade'), |
43 | handler: function() { | |
6ad5f9f2 | 44 | Proxmox.Utils.openXtermJsViewer('upgrade', 0, Proxmox.NodeName); |
c87d46fb | 45 | }, |
81c250bd | 46 | }, |
61415efa | 47 | itemId: 'updates', |
c87d46fb | 48 | nodename: Proxmox.NodeName, |
03912e15 | 49 | }, |
ac6617da | 50 | { |
1b146c10 | 51 | xtype: 'proxmoxJournalView', |
61415efa | 52 | itemId: 'logs', |
ac6617da | 53 | title: gettext('Syslog'), |
c87d46fb | 54 | url: "/api2/extjs/nodes/" + Proxmox.NodeName + "/journal", |
ac6617da | 55 | }, |
03912e15 DM |
56 | { |
57 | xtype: 'proxmoxNodeTasks', | |
61415efa | 58 | itemId: 'tasks', |
03912e15 DM |
59 | title: gettext('Tasks'), |
60 | height: 'auto', | |
c87d46fb TL |
61 | nodename: Proxmox.NodeName, |
62 | }, | |
63 | ], | |
252645ce DM |
64 | }); |
65 | ||
66 |