小编Viv*_*vek的帖子

Automapper 中的对象返回 null

我正在尝试使用示例示例来映射 CustomerViewItem(Source) 和 Customer(Destination)。

这是我试图映射的源实体

public class CustomerViewItem
{
    public CompanyViewItem companyViewItem { get; set; }
    public string CompanyName { get; set; }
    public int CompanyEmployees { get; set; }
    public string CompanyType { get; set; }
    public string FullName { get; set; }
    public string FirstName { get; set; }
    public string LastName { get; set; }        
    public DateTime DateOfBirth { get; set; }
    public int NumberOfOrders { get; set; }
    public bool VIP { get; set; }
} …
Run Code Online (Sandbox Code Playgroud)

c# automapper

1
推荐指数
2
解决办法
8006
查看次数

标签 统计

automapper ×1

c# ×1