/********省份start*****************/ var storeProvince = new Ext.data.ArrayStore({ fields : [ 'name', 'value' ], url:'queryProvince' }); storeProvince.load(); acceptManager_province = new Ext.form.ComboBox({ renderTo :'province', store : storeProvince, //为省份填充数据 valueField : 'value', displayField : 'name', fieldLabel : '省份', typeAhead : true, mode : 'local', forceSelection : true, triggerAction : 'all', emptyText : '', selectOnFocus : true, width:100, tpl: '<tpl for="."><div ext:qtip="{name}" class="x-combo-list-item">{name}</div></tpl>', listeners: { 'select': function(acceptManager_combo, record, index) { /*获取选中省份ID*/ var proId = record.get('value'); var dataSource = new Ext.data.HttpProxy({ method: 'POST', url: 'queryCityPro' }); acceptManager_storeCity.baseParams = {m_proId: proId}; acceptManager_storeCity.proxy = dataSource; acceptManager_storeCity.load(); acceptManager_city.clearValue(); acceptManager_city.setValue(""); }} }); /********省份end*****************/ //var acceptManager_data = [['全选','1'],['西安','2'],['深圳','3'],['北京','4'],['上海','5']]; /********城市start*****************/ acceptManager_storeCity = new Ext.data.SimpleStore({ fields: [ "name","value" ], //proxy: new Ext.data.MemoryProxy(acceptManager_data) url:'queryCity' }); acceptManager_storeCity.load(); acceptManager_city = new Ext.form.MultiComboSearch({ renderTo :'city', store:acceptManager_storeCity, valueField :"value", displayField: "name", labelSeparator:':', displaySeparator:',', //多选显示分隔字符 valueSeparator:',',//多选提交到后台的值分隔符 mode: 'local', value:'', forceSelection: true, hiddenName:'test', editable: false, triggerAction: 'all', emptyText:'', fieldLabel: '城市', width:100 }); /********省份end*****************/
详细解决方案
Ext combo 上拉框级联
热度:708 发布时间:2012-10-09 10:21:45.0
相关解决方案
- .关于EXTJS combo 下拉树的有关问题
- Easyui - combo[tree,box]下拉图标有间隙bug解决办法
- How to get dispayfield in extjs combo
- EXTJS editorgrid combo render有关问题
- sexy combo 数据量大的时分好慢
- Ext combo 上拉框级联
- Ext Combo 平添空值并且显示出来
- Ext 2.x combo keyup事件没法响应
- ExtJs 中 combo 取得displayField 和 valueField
- 在 ExtJs 中实现上拉列表(combo)联动
- 拼音输入法上输入字母Ext combo
- ExtJS Combo box Store 加载两次有关问题
- ExtJS4除了下拉框的光标(remove the cursor of combo)
- combo box控件收起下拉后,遮挡了其他控件解决思路
- jquery.combo.select.js下拉框筛选
- Combo box的使用
- Combo Cleaner for Mac(Mac系统清理)破解版
- 思维/差分: Perform the Combo
- easyUI combo textbox datebox 默认高度问题