]>
Commit | Line | Data |
---|---|---|
7bf889cb DM |
1 | Ext.define('PMG.MailProxyPorts', { |
2 | extend: 'Proxmox.grid.ObjectGrid', | |
3 | alias: ['widget.pmgMailProxyPorts'], | |
4 | ||
98d2cb7f DM |
5 | url: '/api2/json/config/mail', |
6 | ||
5e453db7 DM |
7 | monStoreErrors: true, |
8 | ||
98d2cb7f DM |
9 | editorConfig: { |
10 | url: '/api2/extjs/config/mail', | |
11 | }, | |
12 | ||
13 | interval: 5000, | |
14 | ||
15 | cwidth1: 200, | |
16 | ||
17 | controller: { | |
18 | ||
19 | xclass: 'Ext.app.ViewController', | |
20 | ||
21 | onEdit: function() { | |
22 | this.getView().run_editor(); | |
23 | } | |
24 | }, | |
25 | ||
26 | listeners: { | |
27 | itemdblclick: 'onEdit', | |
28 | }, | |
29 | ||
30 | tbar: [ | |
31 | { | |
32 | text: gettext('Edit'), | |
33 | xtype: 'proxmoxButton', | |
34 | disabled: true, | |
35 | handler: 'onEdit' | |
36 | } | |
37 | ], | |
38 | ||
7bf889cb DM |
39 | initComponent : function() { |
40 | var me = this; | |
41 | ||
4fad6a19 DM |
42 | me.add_integer_row('ext_port', gettext('External SMTP Port'), |
43 | { defaultValue: 26, deleteEmpty: true, | |
44 | minValue: 1, maxValue: 65535 }); | |
45 | ||
46 | me.add_integer_row('int_port', gettext('Internal SMTP Port'), | |
47 | { defaultValue: 25, deleteEmpty: true, | |
48 | minValue: 1, maxValue: 65535 }); | |
7bf889cb | 49 | |
7bf889cb DM |
50 | me.callParent(); |
51 | ||
00564597 | 52 | me.on('activate', me.rstore.startUpdate); |
7bf889cb | 53 | me.on('destroy', me.rstore.stopUpdate); |
00564597 | 54 | me.on('deactivate', me.rstore.stopUpdate); |
7bf889cb DM |
55 | } |
56 | }); |