Hi guys,
have a question regarding Field's binding.
I've got a model similar to this one:
public class Person
{ public string Id { get; set; }
public string Name { get; set; }
public List<Orders> Orders { get; set; }
}
public class Order{
public string Id { get; set; }
public class ViewModel
{
public ObservableCollection<Person> { get; set; }
I''m binding List<Person> to XamTreeGrid and displaying data using XAML like:
<igDP:XamTreeGrid.FieldLayouts> <igDP:FieldLayout Key="Person" IsDefault="True"> <igDP:Field Name="Orders" Label="Orders:" /> <igDP:TextField Name="Id" Label="Id" /><igDP:TextField Name="Name" Label="Name" /> </igDP:FieldLayout> <igDP:FieldLayout Key="Order" IsDefault="False"><igDP:TextField Name="id" Label="Id" /><igDP:TextField Name="Name" Label="Name" /> </igDP:FieldLayout> </igDP:XamTreeGrid.FieldLayouts>
All looks good.
The problem comes when I need to introduce one more layer (my architecture needs that) and the code looks like:
public class Wrapper<T>
public T Data { get; set; }
public ObservableCollection<Wrapper<Person>> { get; set; }
Hello Dariusz,
Thank you for your post.
I have been looking into it. I am not sure that understand your issue and scenario correctly, would you please provide me with more details about them. I created short sample application based on your scenario, it will be great if you could modify it with the functionality that you are using, so I will be able to investigate you issue.
Looking forward to hearing from you.
Hi,
In your sample app you implemented the first bit, the one that actually works.
The problem is the second bit - when I introduce Wrapper<T>
thanks