Add project files.

This commit is contained in:
2022-10-06 16:53:07 +03:00
parent 45fac5e086
commit 6f3acce7d4
38 changed files with 1051 additions and 0 deletions
+34
View File
@@ -0,0 +1,34 @@
using AutoMapper;
using PracticeCalendar.Domain.Entities;
namespace PracticeCalendar.API.Model
{
public class EventModel
{
public int Id { get; set; }
public string Title { get; set; }
public string Description { get; set; }
public DateTime StartTime { get; set; }
public DateTime EndTime { get; set; }
public AttendeeModel[] Attendees { get; set; } = new AttendeeModel[0];
}
public class AttendeeModel
{
public string Name { get; set; }
public string EmailAddress { get; set; }
public bool IsAttending { get; set; }
}
public class EventModelProfile : Profile
{
public EventModelProfile()
{
CreateMap<PracticeEvent, EventModel>();
CreateMap<EventModel, PracticeEvent>();
CreateMap<Attendee, AttendeeModel>();
}
}
}