-1

I am new in Extjs, but i build a Extjs tree using Json data, also provided it checkbox in the tree nodes. But my requirement is now to have a new icon before the checkbox (parallely) of each node and also need to find the events on those icon and checkbox.

I googled a lot for such icons (seems it uses elbow css class internally). Can anyone suggest me or give me some sample example to accomplish the task.

thanks

You may see the uploaded image at: http://imageshack.us/photo/my-images/707/v1s5.png/

Nitin Soni
  • 87
  • 1
  • 13
  • 1
    How is what you're asking for any different from the stock "check tree" example that is in the Ext JS docs? http://docs-origin.sencha.com/extjs/4.1.3/#!/example/tree/check-tree.html – Chris Farmer Sep 02 '13 at 00:10
  • hi Chris, thanks for the reply, i have done what is mentioned in your example, but i need new icons before each checkbox on each node too. Can you please look at the image I have mentioned in my question. – Nitin Soni Sep 02 '13 at 10:47

1 Answers1

0

If you're just looking to change the icon, then look at the iconCls attribute of the NodeInterface class.

http://docs-origin.sencha.com/extjs/4.1.3/#!/api/Ext.data.NodeInterface-cfg-iconCls

You supply a class name here, and then in your css you should give that class a background image:

.iconImage{
    background-image: url(image.png) !important;
}
Chris Farmer
  • 24,974
  • 34
  • 121
  • 164