Hi Guys,
I'm trying to insert a treeview in my application so i checked your online examples..
My scenario would fall into "Binding to a remote data" but it's a little more complex.
I have 3 different objects that I need to put in my tree (they came from EF and they are not linked automatically - ef and oracle doesn't work with FK on unic constraints):
Object A
ObjectA is the main-level object...it will occurs only on the root level of the tree.
Each Object A always have a list of object B
ObjectB
each ObjectB always have a list of object C
ObjectC
Here's a tricky part...
Each objectC may have a list of objectC...
now..In your example the read method of the tree call always the same action and whether or not has a parameter load a different node.
In my case I have different object...Is there a way to Implement your example in my scenario?
I guess that, if there's not, I'll have to load all root-nodes and with js load every node's children on click.
I already tried this one and my tree doesn't have to icon to expand a node. I also tried adding to objecta a bool property (like HasChild) and also to fullfill the child list in the first call.
Same appens if I try to replicate your example..I load the root-level but no node is expandable..so it never call the action with the id param.
What Am I doing wrong?
Thanks
Fabio
I'm trying to insert a treeview in my application so i checked your online examples..
My scenario would fall into "Binding to a remote data" but it's a little more complex.
I have 3 different objects that I need to put in my tree (they came from EF and they are not linked automatically - ef and oracle doesn't work with FK on unic constraints):
Object A
public int ID { get; set; } public long CLASSID { get; set; } public string NAME { get; set; } public virtual IEnumerable<ObjectB> DataGroups { set; get; }ObjectA is the main-level object...it will occurs only on the root level of the tree.
Each Object A always have a list of object B
ObjectB
public int ID { get; set; } public long CLASSID { get; set; } public string NAME { get; set; } public long PARENTID { get; set; }public virtual IEnumerable<ObjectC> DataClasses {set;get;}each ObjectB always have a list of object C
ObjectC
public decimal ID { get; set; } public string NAME { get; set; } public long PARENTID { get; set; } public long CLASSID { get; set; }
Here's a tricky part...
Each objectC may have a list of objectC...
now..In your example the read method of the tree call always the same action and whether or not has a parameter load a different node.
In my case I have different object...Is there a way to Implement your example in my scenario?
I guess that, if there's not, I'll have to load all root-nodes and with js load every node's children on click.
I already tried this one and my tree doesn't have to icon to expand a node. I also tried adding to objecta a bool property (like HasChild) and also to fullfill the child list in the first call.
Same appens if I try to replicate your example..I load the root-level but no node is expandable..so it never call the action with the id param.
What Am I doing wrong?
Thanks
Fabio