Friday 15 January 2010

treepanel - Extjs4 treenodes click error -


I am working in extjs4. I have made Treeview as -

  Ext.define ('Balaee.view.qb.qbquestion.tree1', 'extend:' Ext.tree.Panel ', title:' Simple Tree ',' Width: 200, id: 'tree 1', height: 150, alias: 'widget.tree1', store: 'qb.qbquestionStore', displayField: 'text', rootVisible: true, multiSelect: true, valueField: 'Id' RenderTo: Ext.getBody (),},   

Sends Jason through the server up right connected to the paperpanel but whreen I try to click on treenodes This is giving me an error as "TypeError: listener.fireFn is undefined" Mozilla Fire "Uncaught TypeError: Method Can not Call Calls" and "Undefined" Nodes are expanded once only to the itemclick in the controller, I've written the code - "

  init: function () {this.control ({'tree1': {itemclick: {fn: function (view, record, item, index, e) {if (record.data.checked == true) { Console.log (record.data.id)}}}},   

So what should I do to delete the error?

'tree 1' is an incorrect selector. this.control ({'#'} hashtag # : Tree1 ': {

UPDATE

line me Misses alias: 'widget.tree1' . That's why your selector was right.

Try changing the listener:

  'tree1': {itemclick: function (see, record, item, index , E) {if (record.data.checked == true} {console.log (record.data.id);}}   

I believe that in your code The listener's format is not supported Ted.

No comments:

Post a Comment