Version. next Author: tydeas_dr Author: Alexander Makarov, Sam Dark Author: [Alexander Kozhevnikov, Bethrezen)(mailto:b37hr3z3n@gmail.com) Copyright © 2010 Evresis
EJNestedTreeActions IS NOT:
- a nested set behavior for your model
- a jstree extension
EJNestedTreeActions IS only a set of actions and a behavior and you as well need:
- ENestedSetBehavior extension
- CJstree 1.1 extension Attention Cjstree must be at version 1.1 or else won't work
- And of course jsTree v.0.9.9.a
To make your model act like a nested set you will need the ENestedSetBehavior, as we said before. This extension make your model to be able to append,prepend,return the children etc.
At view we have the pretty one jstree. To use the jstree you will need the CJstree extension ( found as jstree extension ). This will give you the ability to drag & drop, copy & paste, create new nodes etc. at your view.
This is where EJNestedTreeActions comes. The jstree has the ability to use async ajax to make request and get results. This async request will call a controller's action to do so. This is what the EJNestedTreeActions does. Take the request from the jstree make the appropriate append,prepend, etc for your model and return data to the jstree.
You first create you table and use the ENestedBehavior like it is described in it's documentation. Use the EJNestedTreeBehavior as described in documentation. Use CJstree as described in it's documentation.
To clone project from the github repository:
git clone git://github.com/dmtrs/EJNestedTreeActions.git
I would like to thank the CJstree author shocky, the ENestedBehavior author creocoder, samdark, the Evresis team, the people from #yii at freenode in general and specially Javache for the help on this.
###Resources
- Yii extension site The yii extension site.
- Github repository For the latest version and official issue reporting.
- Join discussion All suggestions, contributes, ideas are welcome.