您的位置:首页 > Web前端 > JavaScript

ExtJs ComboBox 动态创建下拉框

2017-06-23 09:33 239 查看
注:store中的url需要返回一个格式为[["1","a"]["2","b"]["3","c"]]的json格式的数据
var storeDept = new Ext.data.SimpleStore({
url:'<%=path %>/oneCardPassage/findCardDepartMentInfo.do',
fields:['value','text']
});

var deptCombo = new Ext.form.ComboBox({
id:'deptId',
width:100,
mode : 'remote',
triggerAction : 'all',
selectOnFocus : true,
forceSelection : true,
editable : false,
valueField : 'value',
displayField : 'text',
emptyText:'部门'},
store:storeDept
)
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: