Nightwish
15 Jun 2010, 12:08 PM
This has been driving me crazy and I cannot see what I am doing wrong... it's going to be some simple setting, I know it. Any help appreciated!
MyComboUi = Ext.extend(Ext.form.ComboBox, {
fieldLabel: 'Month/Year',
anchor: '100%',
store: 'MonthYearStore',
valueField: 'ID',
displayField: 'Text',
hiddenId: 'EpisodeMonthYear',
hiddenName: 'EpisodeMonthYear',
mode: 'remote',
forceSelection: true,
initComponent: function() {
MyComboUi.superclass.initComponent.call(this);
}
});
SDMonthYearStore = Ext.extend(Ext.data.JsonStore, {
constructor: function(cfg) {
cfg = cfg || {};
StormDatMonthYearStore.superclass.constructor.call(this, Ext.apply({
storeId: 'MonthYearStore',
root: 'Data',
idProperty: 'ID',
totalProperty: 'TotalCount',
autoSave: false,
url: '/sd/api.svc/lookup/MonthYearData',
autoLoad: true,
restful: false,
sortField: 'ID',
sortDir: 'DESC',
fields: [
{
name: 'ID',
type: 'string'
},
{
name: 'Text',
type: 'string'
}
]
}, cfg));
}
});
new SDMonthYearStore();
MyComboUi = Ext.extend(Ext.form.ComboBox, {
fieldLabel: 'Month/Year',
anchor: '100%',
store: 'MonthYearStore',
valueField: 'ID',
displayField: 'Text',
hiddenId: 'EpisodeMonthYear',
hiddenName: 'EpisodeMonthYear',
mode: 'remote',
forceSelection: true,
initComponent: function() {
MyComboUi.superclass.initComponent.call(this);
}
});
SDMonthYearStore = Ext.extend(Ext.data.JsonStore, {
constructor: function(cfg) {
cfg = cfg || {};
StormDatMonthYearStore.superclass.constructor.call(this, Ext.apply({
storeId: 'MonthYearStore',
root: 'Data',
idProperty: 'ID',
totalProperty: 'TotalCount',
autoSave: false,
url: '/sd/api.svc/lookup/MonthYearData',
autoLoad: true,
restful: false,
sortField: 'ID',
sortDir: 'DESC',
fields: [
{
name: 'ID',
type: 'string'
},
{
name: 'Text',
type: 'string'
}
]
}, cfg));
}
});
new SDMonthYearStore();