sfwalter
16 Apr 2007, 8:23 AM
I have an editable grid and I am trying to get type ahead to work. I can get it to work if I create a select tag (make it hidden) in the html just like the editable grid demo.
However I would like to populate the combobox with a store. When I use a store for some reason type ahead doesn't work. Here is what I have:
var priorities = [
['Shade', 'Shade'],
['Mostly Shady', 'Mostly Shady'],
['Mostly Sunny', 'Mostly Sunny'],
['Sun or Shade', 'Sun or Shade'],
['Sunny', 'Sunny']
];
prioritiesStore = new Ext.data.SimpleStore(
{ id:0,
fields: ['name', 'description'],
data : priorities
}
);
and here is the definition of the combobox in my column model:
{ header: "Priority",
width: 50,
sortable: true,
align: 'center',
resizable: false,
locked:false,
dataIndex: 'priority',
//renderer: renderPriority,
editor:
new Ed(new fm.ComboBox(
{ typeAhead: true,
triggerAction: 'all',
lazyRender:true,
//transform:'light'
store:prioritiesStore,
displayField:'description',
valueField:'name'
}
)
)
},
Am I doing something wrong or could this possible be a defect? FYI I am using version 1.0
cheers,
scott
However I would like to populate the combobox with a store. When I use a store for some reason type ahead doesn't work. Here is what I have:
var priorities = [
['Shade', 'Shade'],
['Mostly Shady', 'Mostly Shady'],
['Mostly Sunny', 'Mostly Sunny'],
['Sun or Shade', 'Sun or Shade'],
['Sunny', 'Sunny']
];
prioritiesStore = new Ext.data.SimpleStore(
{ id:0,
fields: ['name', 'description'],
data : priorities
}
);
and here is the definition of the combobox in my column model:
{ header: "Priority",
width: 50,
sortable: true,
align: 'center',
resizable: false,
locked:false,
dataIndex: 'priority',
//renderer: renderPriority,
editor:
new Ed(new fm.ComboBox(
{ typeAhead: true,
triggerAction: 'all',
lazyRender:true,
//transform:'light'
store:prioritiesStore,
displayField:'description',
valueField:'name'
}
)
)
},
Am I doing something wrong or could this possible be a defect? FYI I am using version 1.0
cheers,
scott