これはグリッド用の私の JsonStore です。
var itemListStore = new Ext.data.JsonStore({
id : 'itemListStore',
proxy : new Ext.data.HttpProxy({
url : 'test.php',
}),
totalCnt : 'totalCnt', // ?
lastUpdate : 'lastUpdate', // ?
root : 'content', // it works ok
fields : [
{name : 'name', type : 'string'},
{name : 'id', type : 'string'},
],
autoLoad: true,
listeners : {
load : function(){
// I need to get the totalCnt and lastUpdate field value
alert(this.lastUpdate); // output : lastUpdate -,.-
}
}
});
プロキシデータは次のようになります
{"totalCnt":95,"lastUpdate":"2011-08-01 09:20:03.000","content":[{"name":"MURRAY MP220GF............. .....
content(root) でグリッドを描画できますが、load 関数で totalCnt フィールドと lastUpdate フィールドを取得できません。
誰もこれを知っています、私を助けてください
ありがとう。