mirror of
https://git.proxmox.com/git/pve-manager
synced 2025-07-27 00:23:19 +00:00
fix HA Group Selector display
displayField must now be set in class body, take opportunity to move out other config properties from initComponent()
This commit is contained in:
parent
9ccd656a61
commit
7fc52dff20
@ -2,48 +2,42 @@ Ext.define('PVE.ha.GroupSelector', {
|
||||
extend: 'PVE.form.ComboGrid',
|
||||
alias: ['widget.pveHAGroupSelector'],
|
||||
|
||||
initComponent: function() {
|
||||
var me = this;
|
||||
|
||||
var store = new Ext.data.Store({
|
||||
autoSelect: false,
|
||||
valueField: 'group',
|
||||
displayField: 'group',
|
||||
listConfig: {
|
||||
columns: [
|
||||
{
|
||||
header: gettext('Group'),
|
||||
width: 100,
|
||||
sortable: true,
|
||||
dataIndex: 'group'
|
||||
},
|
||||
{
|
||||
header: gettext('Nodes'),
|
||||
width: 100,
|
||||
sortable: false,
|
||||
dataIndex: 'nodes'
|
||||
},
|
||||
{
|
||||
header: gettext('Comment'),
|
||||
flex: 1,
|
||||
dataIndex: 'comment'
|
||||
}
|
||||
]
|
||||
},
|
||||
store: {
|
||||
model: 'pve-ha-groups',
|
||||
sorters: {
|
||||
property: 'group',
|
||||
order: 'DESC'
|
||||
}
|
||||
});
|
||||
},
|
||||
|
||||
Ext.apply(me, {
|
||||
store: store,
|
||||
autoSelect: false,
|
||||
valueField: 'group',
|
||||
displayField: 'group',
|
||||
listConfig: {
|
||||
columns: [
|
||||
{
|
||||
header: gettext('Group'),
|
||||
width: 100,
|
||||
sortable: true,
|
||||
dataIndex: 'group'
|
||||
},
|
||||
{
|
||||
header: gettext('Nodes'),
|
||||
width: 100,
|
||||
sortable: false,
|
||||
dataIndex: 'nodes'
|
||||
},
|
||||
{
|
||||
header: gettext('Comment'),
|
||||
flex: 1,
|
||||
dataIndex: 'comment'
|
||||
}
|
||||
]
|
||||
}
|
||||
});
|
||||
|
||||
me.callParent();
|
||||
|
||||
store.load();
|
||||
initComponent: function() {
|
||||
var me = this;
|
||||
me.callParent();
|
||||
me.getStore().load();
|
||||
}
|
||||
|
||||
}, function() {
|
||||
|
Loading…
Reference in New Issue
Block a user