ExtJS -- 各种Store
来源:互联网 发布:中华小说网源码 编辑:程序博客网 时间:2024/06/05 12:39
//ArrayStorestore: new Ext.data.ArrayStore({fields:[ 'sexTypeid', 'sexTypename'],data:[["MAN","男"],["WOMEN","女"],["NONE","男女不限"]]})//JsonStorenew Ext.data.JsonStore({root:'grid',url: 'getData.action',fields: ['id','name']});var store = new Ext.data.JsonStore({root : 'grid',proxy: new Ext.data.HttpProxy({ url : 'getBdsbcxData.action', timeout: 120000 }),totalProperty: 'totalCount',//sortInfo : {field: "PXBM", direction: "ASC"},fields : ['SBMC','SSBDZMC','DYDJMC']});//Storevar store = new Ext.data.Store({proxy: new Ext.data.HttpProxy({ url : 'getSbjhtjMxb.action', timeout: 12000 }), reader : new App.JsonReader/*原为Ext.data.JsonReader*/({ root : 'grid' },['id', 'zbid', 'dwdm', 'dwmc'])});/** * 扩展JsonReader,使store.reload(callback:function(){此处可获取自定义属性}) * @class App.JsonReader * @extends Ext.data.JsonReader */App.JsonReader = Ext.extend(Ext.data.JsonReader, { read : function(response){ var json = response.responseText; var o = Ext.decode(json); this.responseText = json;//add by ljm if(!o) { throw {message: 'JsonReader.read: Json object not found'}; } return this.readRecords(o); } });//App.JsonReader 是为了store.reload({params : { bmStr : bmStr },callback:function(r,options,success){ myMask.hide(); var resp = Ext.util.JSON.decode(store.reader.responseText);//可获取到后台返回的自定义属性 }
0 0
- Extjs 各种store示例
- ExtJS -- 各种Store
- ExtJS store
- extjs store
- extjs store
- extjs store
- extjs store
- ExtJs store
- extjs store
- ExtJs常用数据源store
- ExtJs Store baseParams设置
- extjs之访问store
- Extjs 高级store
- extjs之访问store
- extjs构造store 实例
- Extjs Store使用
- extJs之store
- ExtJs Store注意事项
- 正则表达式学习笔记
- ExtJS -- 改变树节点图标 tree
- 生活杂文
- 程序员的成长和代码行数的关系
- 对话:一个工程师在蘑菇街4年的架构感悟
- ExtJS -- 各种Store
- iOS 取得ipa里面的图片
- 58-Odd Even Linked List
- 使用sync adapte(二)创建一个Authenticator
- 学习Handler、MessageQueue、Looper及其之间的关系
- ExtJS -- renderer 参数
- 设计模式之代理模式
- LCD
- poj1144(求割点)