var RecordDef = Ext.data.Record.create([
{name: 'id'},{name: 'name'}
]);
var dataStore=new Ext.data.Store({
proxy: new Ext.data.HttpProxy({url: 'loadDataDic.action'}),
reader: new Ext.data.JsonReader({
id:"id"
}, RecordDef),
remoteSort: true
});
dataStore.load();
=============================
form1 = new Ext.FormPanel({
// collapsible : true, 是否可以展开
labelWidth : 75,
frame : true,
title : '留言管理',
bodyStyle : 'padding:5px 5px 0',
width : 400,
waitMsgTarget : true,
reader : _jsonFormReader,
defaults : {
width : 230
},
defaultType : 'textfield',
items : [{
xtype:'combo',
store: dataStore,
valueField :"retrunValue",
displayField: "displayText",
//数据是在本地
mode: 'local',
//forceSelection: true,必须选择一项
emptyText:'请选择处理结果...',//默认值
//hiddenName:'education',hiddenName才是提交到后台的input的name
editable: false,//不允许输入
triggerAction: 'all',//因为这个下拉是只能选择的,所以一定要设置属性triggerAction为all,不然当你选择了某个选项后,你的下拉将只会出现匹配选项值文本的选择项,其它选择项是不会再显示了,这样你就不能更改其它选项了。
//allowBlank:false,//该选项值不能为空
fieldLabel: '处理结果',
id : 'com',
name: 'education',
anchor:'87%'
},{
xtype:'textarea',
id:'message.cljg',
height:200,
width : 320
}],
buttons : [{
text : ' 返 回 ',
handler : function() {
newFormWin.hide();
}
}]
});
这样写,根本就没进到我的action啊?我把数据源load了啊,请问是怎么回事啊?