2
工作,我有2类:“包括” 扩展方法不LinqKit
public class Employee
{
public int Id {get;set;}
public string Name {get;set;}
}
public class Remuneration
{
public int Id {get;set;}
public Employee Employee {get;set;}
public int Amount {get;set;}
}
正常查询:
return _context.Remunerations.Include("Employee")
完美的作品
但是,当我使用阿尔巴哈利的LinqKit和给出如下查询:
return _context.Remunerations.AsExpandable().Include("Employee")
它不会给出任何错误。
但在结果中不包含Employee数据。