ahsec
17 Apr 2012, 8:48 AM
Hi everybody...I've started using the EXTDesigner to build my GUI.
my first step was trying to build a combobox and load a static(local) data into it.
here is my combobox on EXT Designer
34114
as you can see it's very simple..the problem starts..well..when I'm trying to add data to the store..
I've tried to use both array store and array store..neither worked...
when I add , say, six rows to the data of the store, this is the result
34115
I get six empty rows!!!!!
this is what I have in my data box in EXTDesigner forthe store:
[{age:10},{age:10},{age:10},{age:10},{age:10},{age:10}]
and the field has in the "name" box: age , and in the type box: int.
it clearly seems that the box gets the data yet can't find any of the fields...any ideas?
here's my code in the store file generated (exported) by the designer:
Ext.define('MyApp.store.d_AppsStoreArr', {
extend: 'Ext.data.Store',
constructor: function(cfg) {
var me = this;
cfg = cfg || {};
me.callParent([Ext.apply({
autoLoad: true,
storeId: 'd_AppsStoreArr',
clearOnPageLoad: false,
data: [
{
age: 10
},
{
age: 10
},
{
age: 10
},
{
age: 10
},
{
age: 10
},
{
age: 10
}
],
proxy: {
type: 'ajax',
reader: {
type: 'array'
}
},
fields: [
{
name: 'age',
type: 'int'
}
]
}, cfg)]);
}
});
my first step was trying to build a combobox and load a static(local) data into it.
here is my combobox on EXT Designer
34114
as you can see it's very simple..the problem starts..well..when I'm trying to add data to the store..
I've tried to use both array store and array store..neither worked...
when I add , say, six rows to the data of the store, this is the result
34115
I get six empty rows!!!!!
this is what I have in my data box in EXTDesigner forthe store:
[{age:10},{age:10},{age:10},{age:10},{age:10},{age:10}]
and the field has in the "name" box: age , and in the type box: int.
it clearly seems that the box gets the data yet can't find any of the fields...any ideas?
here's my code in the store file generated (exported) by the designer:
Ext.define('MyApp.store.d_AppsStoreArr', {
extend: 'Ext.data.Store',
constructor: function(cfg) {
var me = this;
cfg = cfg || {};
me.callParent([Ext.apply({
autoLoad: true,
storeId: 'd_AppsStoreArr',
clearOnPageLoad: false,
data: [
{
age: 10
},
{
age: 10
},
{
age: 10
},
{
age: 10
},
{
age: 10
},
{
age: 10
}
],
proxy: {
type: 'ajax',
reader: {
type: 'array'
}
},
fields: [
{
name: 'age',
type: 'int'
}
]
}, cfg)]);
}
});