idProperty: 'id',
});
-Ext.define('PMG.AttachmentQuarantineController', {
- extend: 'PMG.controller.QuarantineController',
- alias: 'controller.attachmentquarantine',
- xtype: 'pmgAttachmentQuarantineController',
-
- onSelectMail: function() {
- let me = this;
- let list = this.lookupReference('list');
- let selection = list.selModel.getSelection();
- if (selection.length <= 1) {
- let rec = selection[0] || {};
- me.lookup('attachmentlist').setID(rec);
- }
-
- me.callParent();
- },
-
- control: {
- 'button[reference=raw]': {
- click: 'toggleRaw',
- },
- 'pmgQuarantineList': {
- selectionChange: 'onSelectMail',
- },
- },
-
-});
-
Ext.define('PMG.AttachmentQuarantine', {
extend: 'Ext.container.Container',
xtype: 'pmgAttachmentQuarantine',
downloadMailURL: get => '/api2/json/quarantine/download?mailid=' + encodeURIComponent(get('mailid')),
},
},
- controller: 'attachmentquarantine',
+ controller: 'quarantine',
items: [
{
title: gettext('Attachment Quarantine'),
xtype: 'pmgQuarantineList',
emptyText: gettext('No data in database'),
selModel: 'checkboxmodel',
- emailSelection: false,
+ quarantineType: 'attachment',
reference: 'list',
region: 'west',
width: 500,
dockedItems: [
{
xtype: 'toolbar',
+ overflowHandler: 'scroller',
dock: 'top',
items: [
{
enableToggle: true,
iconCls: 'fa fa-file-code-o',
},
+ {
+ xtype: 'tbseparator',
+ reference: 'themeCheckSep',
+ },
+ {
+ xtype: 'proxmoxcheckbox',
+ reference: 'themeCheck',
+ checked: true,
+ boxLabel: gettext('Dark-mode filter'),
+ iconCls: 'fa fa-paint-brush',
+ },
'->',
{
xtype: 'button',
},
],
},
- {
- xtype: 'pmgAttachmentGrid',
- minHeight: 50,
- maxHeight: 250,
- scrollable: true,
- reference: 'attachmentlist',
- },
{
xtype: 'pmgMailInfo',
hidden: true,
reference: 'mailinfo',
},
+ {
+ xtype: 'pmgAttachmentGrid',
+ reference: 'attachmentlist',
+ dock: 'bottom',
+ collapsible: false,
+ },
],
},
],