[pbs-devel] [PATCH proxmox-backup v3 2/3] ui: Show if Filter includes or excludes
Philipp Hufnagl
p.hufnagl at proxmox.com
Thu Nov 30 08:21:57 CET 2023
On 11/28/23 14:49, Dominik Csapak wrote:
> On 11/28/23 11:40, Philipp Hufnagl wrote:
> [snip]
>> @@ -384,6 +413,82 @@ Ext.define('PBS.form.GroupFilter', {
>> },
>> });
>> +Ext.define('PBS.form.pbsGroupBehaviorSelector', {
>> + extend: 'Proxmox.form.KVComboBox',
>> + alias: 'widget.pbsGroupBehaviorSelector',
>> +
>> + allowBlank: false,
>> +
>> + comboItems: [
>> + ['include', gettext('Include')],
>> + ['exclude', gettext('Exclude')],
>> + ],
>> +});
>> +Ext.define('PBS.form.GroupFilterGrid', {
>> + extend: 'Ext.grid.Panel',
>> + alias: 'widget.pbsGroupFilterGrid',
>> +
>> + scrollable: true,
>> + height: 200,
>> + store: {
>> + fields: ['type', 'input'],
>> + },
>> + columns: [
>> + {
>> + text: gettext('Filter Type'),
>> + xtype: 'widgetcolumn',
>> + dataIndex: 'type',
>> + flex: 1,
>> + widget: {
>> + xtype: 'pbsGroupFilterTypeSelector',
>> + isFormField: false,
>> + },
>> + },
>> + {
>> + text: gettext('Filter Value'),
>> + xtype: 'widgetcolumn',
>> + flex: 1,
>> + onWidgetAttach: 'newInputColumn',
>> + widget: {
>> + padding: 0,
>> + bodyPadding: 0,
>> + xtype: 'fieldcontainer',
>> + layout: 'fit',
>> + defaults:
>> + {
>> + margin: 0,
>> + },
>> + items: [
>> + {
>> + hidden: true,
>> + xtype: 'pbsGroupTypeSelector',
>> + isFormField: false,
>> + },
>> + {
>> + hidden: true,
>> + xtype: 'textfield',
>> + type: 'regex',
>> + isFormField: false,
>> + },
>> + {
>> + hidden: true,
>> + xtype: 'pbsGroupSelector',
>> + isFormField: false,
>> + },
>> + ],
>> + },
>> + },
>> + {
>> + xtype: 'widgetcolumn',
>> + width: 30,
>
> here you change the width of the remove button, which makes it too narrow
> and cuts of the icon, please leave the space of this the same as before
Ah thank you! I was wondering about that. I did not want to change it
because I did not touch the vertical sizes anywhere else.
I'll make a new version!
>
>> + widget: {
>> + xtype: 'button',
>> + iconCls: 'fa fa-trash-o',
>> + },
>> + },
>> + ],
>> +});
>> +
>> Ext.define('PBS.form.GroupFilterTypeSelector', {
>> extend: 'Proxmox.form.KVComboBox',
>> alias: 'widget.pbsGroupFilterTypeSelector',
>
>
More information about the pbs-devel
mailing list