2
J'ai un JSONStore comme:ExtJS JsonStore ne se charge pas proeprly
OrdersStore = Ext.extend(Ext.data.JsonStore, {
constructor: function(cfg) {
cfg = cfg || {};
OrdersStore.superclass.constructor.call(this, Ext.apply({
storeId: 'ordersStore',
url: '/ajaxSupport.action',
root: 'rows',
baseParams: {
action: 'getorderlegsearchgrid'
},
fields: [
{
name: 'orderId'
}
]
},
cfg));
}
});
new OrdersStore();
Ce magasin est attaché à une grille: 'pendingOrdersGrid'. Quand je fais:
alert(Ext.util.JSON.encode(this.pendingOrdersGrid.getStore().getAt(0)));
J'espère obtenir le premier enregistrement. Mais je reçois « null »
vous devriez vraiment utiliser Firebug, qui rendra la vie beaucoup plus facile si vous faites affaire avec ExtJS – sra