Fixed API folder name
This commit is contained in:
16
Birdmap.API/MapperProfiles/BirdmapProfile.cs
Normal file
16
Birdmap.API/MapperProfiles/BirdmapProfile.cs
Normal file
@ -0,0 +1,16 @@
|
||||
using AutoMapper;
|
||||
using Birdmap.DAL.Entities;
|
||||
|
||||
namespace Birdmap.API.MapperProfiles
|
||||
{
|
||||
public class BirdmapProfile : Profile
|
||||
{
|
||||
public BirdmapProfile()
|
||||
{
|
||||
CreateMap<User, DTOs.AuthenticateResponse>()
|
||||
.ForMember(m => m.Username, opt => opt.MapFrom(m => m.Name))
|
||||
.ForMember(m => m.UserRole, opt => opt.MapFrom(m => m.Role))
|
||||
.ReverseMap();
|
||||
}
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user