0
我想填充劍道的TreeView其中2個節點的本地數據源和最後一個節點應該是遠程數據源本地和遠程數據源,以劍道樹形
這裏是我的代碼:
$("#AftermarketTreeView").kendoTreeView({
dataTextField: ["text", "text", "MC_ANALYSIS_NAME"],
dataSource: {
data: [
{
text: "Initiate",
items: [
{ text: "Parts Selection", haschildren: false },
{ text: "Assumptions", haschildren: false },
{ text: "Team", haschildren: false },
]
},
{
text: "Analyze",
items: [
{ text: "Part Attributes", haschildren: false },
{ text: "Aftermarket Evaluation", haschildren: false }
]
},
{
text: "Monto Carlo",
items: [
{ text: "Monto Carlo", haschildren: true }
]
}
],
schema: {
model: {
hasChildren: "items",
children: {
schema: {
data: "items",
model: {
hasChildren: "haschildren",
children: {
schema: {
// override the schema.data setting from the parent
data: function (response) {
return response;
}
},
transport: {
read: {
url: ResolveUrl("/CreateMaintainAnalysis/GetMontoCarloData/"),
dataType: "jsonp",
data:onDataSendAnalysisID,
}
},
}
}
}
}
}
}
}
});
以上使用代碼我得到的結構如下 哪裏啓動和分析本地數據源和蒙託卡羅是遠程數據源,但我不希望該節點再次成爲蒙託卡洛它應該是直接從數據庫遠程數據源
在此先感謝!!!
我嘗試過,但因爲我是新的劍道......無法理解需要放置的位置和位置 – SantyEssac