带有ExtJs的多选组合框 [英] Multiselect combobox with ExtJs
本文介绍了带有ExtJs的多选组合框的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
如何使用ExtJs实现多选择组合框作为 Ext.FormPanel
的一部分?我一直在寻找,但似乎找不到与最新版本的ExtJs兼容的解决方案(这个问题类似,但没有工作/当前解决方案)。
How do you implement a multiselect combobox as part of a Ext.FormPanel
using ExtJs? I've been looking, but can't seem to find a solution that is compatible with the latest version of ExtJs (this question is similar, but doesn't have a working/current solution).
这是我到目前为止,但是它是一个选择:
This is what I have so far, but it's a single select:
new Ext.FormPanel({
labelAlign: 'top',
frame: true,
width: 800,
items: [{
layout: 'column',
items:[{
columnWidth: 1,
layout: 'form',
items: [{
xtype: 'combo',
fieldLabel: 'Countries',
name: 'c[]',
anchor: '95%',
allowBlank: false,
typeAhead: true,
triggerAction: 'all',
lazyRender: true,
mode: 'local',
store: new Ext.data.ArrayStore({
id: 0,
fields: ['myId', 'displayText'],
data: [
["CA", 'Canada'],
["US", 'United States'],
["JP", 'Japan'],
]
}),
valueField: 'myId',
displayField: 'displayText'
}]
}]
}]
}).render(document.body);
我在文档,表明这是支持的。我还发现此和这,但我只能让他们使用Ext 2。
I didn't see any parameters in the documentation that suggests that this is supported. I also found this and this but I could only get them working with Ext 2.
推荐答案
查看 SuperBoxSelect extension。
Check out the SuperBoxSelect extension.
这篇关于带有ExtJs的多选组合框的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文