Hmmm, our code is proprietary...
I'll see what I can do.

Basically, you load-up treegrid in the layout.html like any other 
javascript library (after putting it in the static folder of the app), and 
from then it works via ajax with jquery.
You write a controller-action in web2py that you talk to with that 
ajax-call, and in it you provide a formatted xml in the response.
The xml defines the structure/schema of the data (which columns you have), 
as well as configuration of the treegrid for that particular use-case 
(turning features on and off, defining tree-groupings, etc).
You provide the data itself in a different xml, as a response to 
data-queries from treegrid.
You also need another controller-action for the "save" operation, which 
receives an xml with the changes, and should parse it and store the changes 
in the database.
These are the very basics, obliviously for a larger project like ours, you 
would end-up having a dedicated module to deal with treegrid interactions, 
and use it's methods in the controller-actions. Unfortunately, we are not 
in liberty to share that code... :/

I'll check if we can churn-out some example code, though...
Treegrid itself has a 30 day trial also (with a watermark) so you can 
download and try it out.
There are also many examples on the EJS website, that you can download ant 
try-out (in addition to the online examples).
In general, though, it's not too much different from any other client-side 
widget - the ajax interaction model is basically the same.

-- 

--- 
You received this message because you are subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to web2py+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to