我想要做的是网格列中的过滤器选项。这是专栏:
{
id: 'kleuren',
text: 'Kleuren',
sortable: true,
filterable: true,
minWidth: 60,
flexible: 0,
width: 60,
filter: {
type: 'list',
store: kleuren
},
renderer: kleurenWeergave,
dataIndex: 'kleuren'
}
对于商店/模型,我使用这个
kleurenStore = Ext.create('Ext.data.Store', {
fields: ['id', 'text'],
data: kleurenModel
});
var kleurenModel = [
['rood', 'rood'],
['groen', 'groen'],
['blauw', 'blauw'],
['geel', 'geel']
]
这是我现在的网格
var grid = Ext.create('PersistantSelectionGridPanel', {
autoscroll: true,
region: 'center',
store: allLoaded,
multiSelect: false,
stateful: true,
features: [filtersFeature],
loadMask: false,
stateId: 'stateGrid',
viewConfig: {
stripeRows: true
},
columns: [{....