EasyUI
Home
Demo
Tutorial
Documentation
Download
Extension
Contact
Forum
EasyUI Forum
September 18, 2024, 08:39:57 AM
Welcome,
Guest
. Please
login
or
register
.
1 Hour
1 Day
1 Week
1 Month
Forever
Login with username, password and session length
News
:
Home
Help
Search
Login
Register
EasyUI Forum
>
General Category
>
EasyUI for jQuery
>
Treegrid Dynamic load
Pages: [
1
]
« previous
next »
Print
Author
Topic: Treegrid Dynamic load (Read 6946 times)
zolotoy
Jr. Member
Posts: 89
Treegrid Dynamic load
«
on:
July 28, 2015, 06:12:28 AM »
I am looking into the following example:
http://www.jeasyui.com/tutorial/tree/treegrid3_demo.html
and cannot understand how does it know to go a get children when a node is expanded?
Thanks
Logged
yamilbracho
Jr. Member
Posts: 64
Re: Treegrid Dynamic load
«
Reply #1 on:
July 28, 2015, 08:12:08 AM »
When you click in a node, an ajax call is made and your server side code receives the node id.
In the php code you can see a sql select where parentId is the received id.
You have to build your table with thsi structure:
id, int
parentId, int
...
ParentId = 0 for nodes whose parent is the root of the tree.
HTH,
Yamil
Logged
zolotoy
Jr. Member
Posts: 89
Re: Treegrid Dynamic load
«
Reply #2 on:
July 28, 2015, 08:17:20 AM »
I think it's much more than that. It will go to the server if you have loader specified:
loader:function(param,success,error){
.....
}
Or url property.
If you populate data by other means it wont happen. Can't say it is extremely intuitive.
Logged
Pages: [
1
]
Print
« previous
next »
Jump to:
Please select a destination:
-----------------------------
General Category
-----------------------------
=> News
=> General Discussion
=> EasyUI for jQuery
=> EasyUI for Angular
=> EasyUI for Vue
=> EasyUI for React
=> Bug Report
Loading...