+/*global Proxmox*/
+/*jslint confusion: true*/
+/* bind is a function function */
Ext.define('PMG.RuleInfo', {
extend: 'Ext.panel.Panel',
xtype: 'pmgRuleInfo',
// FIXME
// actions have the ogroup as a string
// -> parseInt
- return (ids.indexOf(parseInt(record.data[idField])) === -1);
+ return (ids.indexOf(parseInt(record.data[idField], 10)) === -1);
}
});
store.load();
'tabpanel[reference=availobjects] > grid': {
drop: 'removeDrop'
}
- },
+ }
},
viewModel: {
data: {
- baseurl: undefined,
+ baseurl: ''
},
stores: {
model: 'pmg-action-list',
proxy: {
type: 'proxmox',
- url: "/api2/json/config/ruledb/action/objects",
+ url: "/api2/json/config/ruledb/action/objects"
},
sorters: 'name'
},
model: 'pmg-object-group',
proxy: {
type: 'proxmox',
- url: "/api2/json/config/ruledb/who",
+ url: "/api2/json/config/ruledb/who"
},
sorters: 'name'
},
model: 'pmg-object-group',
proxy: {
type: 'proxmox',
- url: "/api2/json/config/ruledb/who",
+ url: "/api2/json/config/ruledb/who"
},
sorters: 'name'
},
model: 'pmg-object-group',
proxy: {
type: 'proxmox',
- url: "/api2/json/config/ruledb/what",
+ url: "/api2/json/config/ruledb/what"
},
sorters: 'name'
},
model: 'pmg-object-group',
proxy: {
type: 'proxmox',
- url: "/api2/json/config/ruledb/when",
+ url: "/api2/json/config/ruledb/when"
},
sorters: 'name'
- },
+ }
}
},
defaults: {
- padding: '5 10 5 10',
+ padding: '5 10 5 10'
},
bodyPadding: '5 0 5 0',
items: [
{
xtype: 'panel',
- bodyPadding: 10,
+ bodyPadding: '10 10 10 10',
data: {
- name: false,
+ name: ''
},
bind: {
data: {
'<tpl else>',
gettext('Please select a rule.'),
'</tpl>'
- ],
+ ]
},
{
xtype: 'grid',
{
header: gettext('Type'),
dataIndex: 'oclass',
- hidden: true,
+ hidden: true
},
{
header: gettext('Name'),
bind: {
store: '{objects}',
hidden: '{!selectedRule}'
- },
+ }
},
{
xtype: 'tabpanel',
}
]
}
- ],
+ ]
},
items: [
{
store: '{actionobjects}'
},
type: 'action',
- iconCls: 'fa fa-flag',
+ iconCls: 'fa fa-flag'
},
{
title: gettext('From'),
type: 'from',
bind: {
store: '{fromobjects}'
- },
+ }
},
{
title: gettext('To'),
type: 'to',
bind: {
store: '{toobjects}'
- },
+ }
},
{
title: gettext('What'),
type: 'what',
bind: {
store: '{whatobjects}'
- },
+ }
},
{
title: gettext('When'),
type: 'when',
bind: {
store: '{whenobjects}'
- },
- },
+ }
+ }
]
}
]