extjs4 - Is there any way to disable nodes of treeview in ExtJS 4 -


My purpose is to disable some nodes of tree view in the west region.

The snippet below shows:

  root: {expanded: true, id: 'treeview1', children: [{"text" True: "True, ID: 'HS1', '** disabled **': true," ** hidden ** ": true}}}   

Why does the disabled and hidden assets not work in EXTPS 4?

Is there a plugin to achieve this?

The nodes in the paperpellings are Ext.data.NodeInterface objects.

It does not have a disabled or hidden property, but it has cls and with it you can not add a display: any that hide it Node has been

Example:

  1. In the CSS file:

      .x-hidden-node {display: none! Important:}}    
  2. In the extjs code:

      root: {expanded: true, id: 'treeview1', children: [{Text: 'Copy', Leaf: True, ID: 'HS1', CLS: 'X-Chip-Node'}]}     

    For disabled functionality, you can use the beforeitemClick event in PaperPenel in which you can read the disabled property manually.

    Example:

      Ext (Extttree.Panel ', {(...) Audience: {beforeitemclick: function (treewiewview, record, item, index , E, eops) {if. (record.raw & record.raw.disabled == true) {return false;} re-turned n true;}, itemclick: function (tree view, record, item, index, e, Eoop) {console.log (record, item);}}});    

Comments

Popular posts from this blog

Java - Error: no suitable method found for add(int, java.lang.String) -

java - JPA TypedQuery: Parameter value element did not match expected type -

c++ - static template member variable has internal linkage but is not defined -