we now also disable the edit button if the objectgroup editor has an
'uneditable' flag set, we need this, because the virusfilter has nothing
which we could edit
Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
}
var editor = PMG.Utils.object_editors[rec.data.otype];
- if (!editor) {
+ if (!editor || editor.uneditable) {
return;
}
text: gettext('Edit'),
disabled: true,
selModel: me.selModel,
+ enableFn: function(rec) {
+ var editor = PMG.Utils.object_editors[rec.data.otype];
+ return (editor && !editor.uneditable);
+ },
handler: run_editor
},
remove_btn
xtype: 'pmgWhatConfiguration',
ogclass: 'what',
- otype_list: [3000, 3002, 3003, 3004, 3005]
+ otype_list: [3000, 3001, 3002, 3003, 3004, 3005]
});
}
]
},
+ 3001: {
+ xtype: 'proxmoxWindowEdit',
+ subdir: 'virusfilter',
+ subject: gettext('Virus Filter'),
+ uneditable: true,
+ // there are no parameters to give, so we simply submit it
+ listeners: {
+ show: function(win) {
+ win.submit();
+ }
+ }
+ },
3002: {
xtype: 'proxmoxWindowEdit',
subdir: 'matchfield',