1

嗨朋友们,我是 extjs 4 的新手,how to rename of extjs 4 tree node请给我一个建议,并给我一个参考。
下面的树面板代码

var treePanel = Ext.create('Ext.tree.Panel', {
    id: 'tree-panel',
    title: 'Taxonomy',
    region: 'west',
    collapsible: true,
    split: true,
    //multiSelect: true,                            
    height: '100%',
    width: '20%',
    minWidth: 100,
    rootVisible: false,
    autoScroll: true,
    store: store,
    viewConfig: {
        allowCopy: true,


        plugins: {
            ptype: 'treeviewdragdrop',
            appendOnly: true,
            ddGroup: 'selDD'
        },
4

1 回答 1

0

只需将列配置和编辑器添加到单个列,这就是我认为它在您的代码中的工作方式:

var treePanel = Ext.create('Ext.tree.Panel', {
    id: 'tree-panel',
    title: 'Taxonomy',
    region:'west',
    collapsible: true,
    split: true,
    //multiSelect: true,                            
    height:'100%',       
    width: '20%',
    minWidth: 100,
    rootVisible: false,
    autoScroll: true,
    store: store,
    viewConfig: {
    allowCopy: true,


    plugins: {
        ptype: 'treeviewdragdrop',
        appendOnly: true,
        ddGroup:    'selDD'
    },
    columns: [
       {
           xtype:     "treecolumn",
           dataIndex: "text",
           flex:      1,
           editor:{
               xtype:      "textfield"
           }
       }
    ]
}
于 2013-03-11T19:41:15.650 回答