- 注册时间
- 2012-5-23
- 最后登录
- 2014-5-19
- 阅读权限
- 10
- 积分
- 532
- 精华
- 0
- 帖子
- 164
|
针对这个情况,MiniUI Tree提供了一种直接加载列表数据,Tree内部进行数据转换的方式。
1)从数据库查询出一个列表数据
2)通过JSON方式返回
省略了原来的第2个步骤
这个不太明白 能具体点吗
后台返回怎么样的数据啊
[
{ id:"miniui",text:"miniui",expanded: true,
children[
{id: "base", text: "Base", expanded: false,
children: [
{id: "ajax", text: "Ajax", url: "../../docs/api/ajax.html", target:"_blank"},
{id: "json", text: "JSON", url: "../../docs/api/ajax.html", target:"_blank"}
]
},
{id: "forms", text: "Forms", expanded: false,
children: [
{id: "button", text: "Button", url: "../../docs/api/button.html", target:"_blank"},
{id: "listbox", text: "ListBox", url: "../../docs/api/listbox.html", target:"_blank"},
{id: "checkboxlist", text: "CheckBoxList", url: "../../docs/api/checkboxlist.html", target:"_blank"},
{id: "radiolist", text: "RadioList", url: "../../docs/api/radiolist.html", target:"_blank"}
]
}
]}
]
不需要在后台封装成这样的吗? |
|