2020-01-14 23:27:26 +01:00
|
|
|
|
using AutoMapper;
|
|
|
|
|
using System.Reflection;
|
|
|
|
|
using WebApplication5.Models;
|
|
|
|
|
|
|
|
|
|
namespace WebApplication5
|
|
|
|
|
{
|
|
|
|
|
public class AutoMapperProfile : Profile
|
|
|
|
|
{
|
|
|
|
|
public AutoMapperProfile()
|
|
|
|
|
{
|
2020-06-18 13:42:34 +02:00
|
|
|
|
CreateMap<CategoryViewModel, Category>();
|
|
|
|
|
CreateMap<Category, CategoryViewModel>();
|
|
|
|
|
CreateMap<QuestionViewModel, Question>();
|
|
|
|
|
CreateMap<Question, QuestionViewModel>();
|
|
|
|
|
CreateMap<AnswerViewModel, Answer>();
|
|
|
|
|
CreateMap<Answer, AnswerViewModel>();
|
2020-01-14 23:27:26 +01:00
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|