});
Ext.define('PVE.FirewallRulePanel', {
- extend: 'PVE.panel.InputPanel',
+ extend: 'Proxmox.panel.InputPanel',
allow_iface: false,
// hack: editable ComboGrid returns nothing when empty, so we need to set ''
// Also, disabled text fields return nothing, so we need to set ''
- Ext.Array.each(['source', 'dest', 'macro', 'proto', 'sport', 'dport'], function(key) {
+ Ext.Array.each(['source', 'dest', 'macro', 'proto', 'sport', 'dport', 'log'], function(key) {
if (values[key] === undefined) {
values[key] = '';
}
});
delete values.modified_marker;
-
+
return values;
},
me.column1 = [
{
// hack: we use this field to mark the form 'dirty' when the
- // record has errors- so that the user can safe the unmodified
+ // record has errors- so that the user can safe the unmodified
// form again.
xtype: 'hiddenfield',
name: 'modified_marker',
}
);
-
+
me.column2 = [
{
xtype: 'proxmoxcheckbox',
fieldLabel: gettext('Dest. port')
}
];
-
+
+ me.advancedColumn1 = [
+ {
+ xtype: 'pveFirewallLogLevels'
+ }
+ ];
+
me.columnB = [
{
xtype: 'textfield',
});
}
- var ipanel = Ext.create('PVE.panel.InputPanel', {
+ var ipanel = Ext.create('Proxmox.panel.InputPanel', {
isCreate: me.isCreate,
column1: column1,
column2: [
moveRule: function(from, to) {
var me = this;
- if (!me.base_url) {
+ if (!me.base_url) {
return;
}
updateRule: function(rule) {
var me = this;
- if (!me.base_url) {
+ if (!me.base_url) {
return;
}
initComponent: function() {
- /*jslint confusion: true */
var me = this;
if (!me.list_refs_url) {
if (me.allow_groups) {
me.groupBtn = Ext.create('Ext.Button', {
- text: gettext('Insert') + ': ' +
+ text: gettext('Insert') + ': ' +
gettext('Security Group'),
disabled: true,
handler: function() {
if (errors && errors[name]) {
metaData.tdCls = 'proxmox-invalid-row';
var html = '<p>' + Ext.htmlEncode(errors[name]) + '</p>';
- metaData.tdAttr = 'data-qwidth=600 data-qtitle="ERROR" data-qtip="' +
+ metaData.tdAttr = 'data-qwidth=600 data-qtitle="ERROR" data-qtip="' +
html.replace(/\"/g,'"') + '"';
}
return value;
// similar to xtype: 'rownumberer',
dataIndex: 'pos',
resizable: false,
- width: 23,
+ width: 42,
sortable: false,
align: 'right',
hideable: false,
},
width: 100
},
+ {
+ header: gettext('Log level'),
+ dataIndex: 'log',
+ renderer: function(value, metaData, record) {
+ return render_errors('log', value, metaData, record);
+ },
+ width: 100
+ },
{
header: gettext('Comment'),
dataIndex: 'comment',