jQuery EasyUI Form Plugin - Combotree Kombination Baum
Streckt sich von $ .fn.combo.defaults und $ .fn.tree.defaults. Mit $ außer Kraft setzen .fn.combotree.defaults die Standardeinstellungen zurück.
Kombination Baum (combotree) auszuwählen und die Drop-down-Baum zusammen steuern. Es Kombinationsfeld (Combobox) ist ähnlich, mit der Ausnahme, dass die Liste der Ersatzkomponenten in einen Baum. Kombination Baum (combotree) Baum mit Baum staatliche Unterstützung für Multiple-Choice-Kontrollkästchen.
Verlassen Sie sich
- Combo
- Baum
Verwendung
Erstellen Sie eine Kombination aus dem Tag-Baum (combotree).
<Wählen Sie id = "cc" class = "easyui-combotree" style = "width: 200px;" Daten-Optionen = "url: 'get_data.php', erforderlich: true"> </ Select>
Verwenden Sie Javascript, eine Kombination von Baum (combotree) zu erstellen.
<Input id = "cc" value = "01">
$ ( '# Cc'). Combotree ({ url: 'get_data.php', erforderlich: true });
Immobilien
Das Anwesen erstreckt sich von der Kombination (Combo) und Baum (Baum), ist unter einer Kombination aus Baum (combotree) hinzuzufügen oder Attribute umschreiben.
名称 | 类型 | 描述 | 默认值 |
---|---|---|---|
editable | boolean | 定义用户是否可以直接往文本域中输入文字。 | false |
Ereignis
Die Veranstaltung aus einer Kombination (Combo) erweitert und Baum (Baum)
Weg
Die Verfahren erstrecken sich von einer Kombination (Combo), unten eine Kombination von Baum (combotree) ist hinzuzufügen, oder Methoden außer Kraft setzen.
名称 | 参数 | 描述 |
---|---|---|
options | none | 返回选项(options)对象。 |
tree | none | 返回树(tree)对象。下面的实例演示如何取得选中的树节点。
var t = $('#cc').combotree('tree'); // get the tree object var n = t.tree('getSelected'); // get selected node alert(n.text); |
loadData | data | 记住本地的树(tree)数据。 代码实例: $('#cc').combotree('loadData', [{ id: 1, text: 'Languages', children: [{ id: 11, text: 'Java' },{ id: 12, text: 'C++' }] }]); |
reload | url | 再一次请求远程的树(tree)数据。传 'url' 参数来重写原始的 URL 值。 |
clear | none | 清除组件的值。 |
setValues | values | 设置组件值的数组。 代码实例: $('#cc').combotree('setValues', [1,3,21]); |
setValue | value | 设置组件的值。 代码实例: $('#cc').combotree('setValue', 6); |
jQuery Plugin EasyUI