问题描述
为什么列表里面显示没有数据!!!!!!!!!急//EXT页面varaddinzlststus=null;varformStore=newExt.data.Store({proxy:newExt.data.HttpProxy({url:'load.asp'}),reader:newExt.data.JsonReader({root:"rows",totalProperty:"rowcount"},[{name:"key"},{name:"value"}//显示的字段名,与服务器端返回的json中字段一致]),listeners:{load:function(){alert(addinzlststus.getValue());addinzlststus.setValue(addinzlststus.getValue());}}});formStore.load();addinzlststus=newExt.form.ComboBox({name:"addinzlststus",fieldLabel:"资材状态",store:formStore,mode:'local',//这个属性设置为本地triggerAction:'all',hideTrigger:false,allowBlank:false,displayField:'key',//对应数据源字段valueField:'value',emptyText:'请选择资材类别',editable:false});//JSP页面<%@pagecontentType="text/html;charset=GBK"language="java"errorPage=""%><%out.print("{rows:[{'key':'Java','value':'java'},{'key':'EXTJS','value':'extjs'}]}");%>
解决方案
解决方案二:
mode:remote