]>
Commit | Line | Data |
---|---|---|
ff735274 | 1 | /*global Proxmox*/ |
db8f82ca DM |
2 | Ext.define('PMG.VirusCharts', { |
3 | extend: 'Ext.grid.GridPanel', | |
4 | xtype: 'pmgVirusCharts', | |
5 | ||
3755c9e0 | 6 | title: gettext('Statistics') + ': ' + gettext('Virus Charts'), |
c87d46fb | 7 | |
50531ef9 | 8 | border: false, |
db8f82ca DM |
9 | disableSelection: true, |
10 | ||
c87d46fb | 11 | tbar: [{ xtype: 'pmgStatTimeSelector' }], |
db8f82ca | 12 | |
64fb657f | 13 | emptyText: gettext('No data in database'), |
db8f82ca | 14 | viewConfig: { |
c87d46fb | 15 | deferEmptyText: false, |
db8f82ca DM |
16 | }, |
17 | ||
18 | store: { | |
19 | xclass: 'PMG.data.StatStore', | |
c87d46fb TL |
20 | fields: ['name', 'count'], |
21 | staturl: "/api2/json/statistics/virus", | |
db8f82ca DM |
22 | }, |
23 | ||
24 | columns: [ | |
25 | { | |
26 | header: gettext('Name'), | |
27 | flex: 1, | |
c87d46fb | 28 | dataIndex: 'name', |
db8f82ca DM |
29 | }, |
30 | { | |
31 | header: gettext('Count'), | |
32 | width: 150, | |
c87d46fb TL |
33 | dataIndex: 'count', |
34 | }, | |
db8f82ca DM |
35 | ], |
36 | ||
37 | initComponent: function() { | |
38 | var me = this; | |
c87d46fb | 39 | |
db8f82ca | 40 | me.callParent(); |
c87d46fb | 41 | |
db8f82ca | 42 | Proxmox.Utils.monStoreErrors(me, me.store); |
c87d46fb | 43 | }, |
db8f82ca | 44 | }); |