24 lines
630 B
C#
24 lines
630 B
C#
using AutoMapper;
|
|
using PowderCoating.Application.DTOs.ShopWorker;
|
|
using PowderCoating.Core.Entities;
|
|
|
|
namespace PowderCoating.Application.Mappings;
|
|
|
|
public class ShopWorkerProfile : Profile
|
|
{
|
|
public ShopWorkerProfile()
|
|
{
|
|
// Entity to DTO
|
|
CreateMap<ShopWorker, ShopWorkerDto>();
|
|
|
|
// DTO to Entity
|
|
CreateMap<CreateShopWorkerDto, ShopWorker>();
|
|
CreateMap<UpdateShopWorkerDto, ShopWorker>();
|
|
|
|
// Reverse mappings
|
|
CreateMap<ShopWorkerDto, ShopWorker>();
|
|
CreateMap<ShopWorker, CreateShopWorkerDto>();
|
|
CreateMap<ShopWorker, UpdateShopWorkerDto>();
|
|
}
|
|
}
|