我有两个实体设置如下:
public class Operator : Base
{
public String Name { get; set; }
public String Description { get; set; }
public virtual ICollection<Address> Addresses { get; set; }
}
public class Address : Base
{
public String House { get; set; }
//...
public String Type{ get; set; }
public int? ParentOperatorId { get; set; }
public virtual Operator ParentOperator { get; set; }
}
这很好用。我想要做的是当我通过Addresses.Type
获取操作员组子地址时谢谢!