Hi,
I'm new to kendo and i was trying to display a treeView using the ASP MVC approach so i followed the exemple you provided :
var employees = from e in db.Employees
where (id.HasValue ? e.ReportsTo == id : e.ReportsTo == null)
select new
{
id = e.id,
Name = e.FirstName + " " + e.LastName,
hasChildren = e.Employees1.Any()
};
My question is: where the Employees1 comes from ? (I guess from the model) but what is the code inside this function ? where's the recursive function to loop on each child ? Can you provide the model and see what is inside ?
Thanks
I'm new to kendo and i was trying to display a treeView using the ASP MVC approach so i followed the exemple you provided :
var employees = from e in db.Employees
where (id.HasValue ? e.ReportsTo == id : e.ReportsTo == null)
select new
{
id = e.id,
Name = e.FirstName + " " + e.LastName,
hasChildren = e.Employees1.Any()
};
My question is: where the Employees1 comes from ? (I guess from the model) but what is the code inside this function ? where's the recursive function to loop on each child ? Can you provide the model and see what is inside ?
Thanks