0

私はExtJS 3.2を使用していましたが、ツリーパネルを機能させるために、以下のリンクから参照して、それを行うことができました.

https://www.assembla.com/code/yamt/subversion/nodes/trunk/web/js/extjs/examples/ux/XmlTreeLoader.js?rev=9

Ext.tree.TreeLoader が動作していないため、このコードのエラーが発生している ExtJS 4.1 にそのコードを移行する必要があります。では、ExtJS 4.1 で機能させるには、同じコードに最小限の変更を加える必要があります。

4

1 に答える 1

0

Try the following code.This code is taken from Sencha API.

var store = Ext.create('Ext.data.TreeStore', { root: { expanded: true, children: [ { text: "detention", leaf: true }, { text: "homework", expanded: true, children: [ { text: "book report", leaf: true }, { text: "algebra", leaf: true} ] }, { text: "buy lottery tickets", leaf: true } ] } });

Ext.create('Ext.tree.Panel', { title: 'Simple Tree', width: 200, height: 150, store: store, rootVisible: false, renderTo: Ext.getBody() });

Refer API for more details.

于 2013-12-11T09:28:36.933 に答える