]> git.proxmox.com Git - proxmox-widget-toolkit.git/blob - src/panel/PruneKeepPanel.js
panel: add PruneInputPanel
[proxmox-widget-toolkit.git] / src / panel / PruneKeepPanel.js
1 Ext.define('Proxmox.panel.PruneInputPanel', {
2 extend: 'Proxmox.panel.InputPanel',
3 xtype: 'pmxPruneInputPanel',
4 mixins: ['Proxmox.Mixin.CBind'],
5
6 // set on use for now
7 //onlineHelp: 'maintenance_pruning',
8
9 cbindData: function() {
10 let me = this;
11 me.isCreate = !!me.isCreate;
12 return {};
13 },
14
15 column1: [
16 {
17 xtype: 'pmxPruneKeepInput',
18 name: 'keep-last',
19 fieldLabel: gettext('keep-last'),
20 cbind: {
21 deleteEmpty: '{!isCreate}',
22 },
23 },
24 {
25 xtype: 'pmxPruneKeepInput',
26 name: 'keep-daily',
27 fieldLabel: gettext('Keep Daily'),
28 cbind: {
29 deleteEmpty: '{!isCreate}',
30 },
31 },
32 {
33 xtype: 'pmxPruneKeepInput',
34 name: 'keep-monthly',
35 fieldLabel: gettext('Keep Monthly'),
36 cbind: {
37 deleteEmpty: '{!isCreate}',
38 },
39 },
40 ],
41 column2: [
42 {
43 xtype: 'pmxPruneKeepInput',
44 fieldLabel: gettext('Keep Hourly'),
45 name: 'keep-hourly',
46 cbind: {
47 deleteEmpty: '{!isCreate}',
48 },
49 },
50 {
51 xtype: 'pmxPruneKeepInput',
52 name: 'keep-weekly',
53 fieldLabel: gettext('Keep Weekly'),
54 cbind: {
55 deleteEmpty: '{!isCreate}',
56 },
57 },
58 {
59 xtype: 'pmxPruneKeepInput',
60 name: 'keep-yearly',
61 fieldLabel: gettext('Keep Yearly'),
62 cbind: {
63 deleteEmpty: '{!isCreate}',
64 },
65 },
66 ],
67 });