Api/Brizco.Domain/Entities/Complexes/Complex.cs

32 lines
1.2 KiB
C#

using Task = Brizco.Domain.Entities.Tasks.Task;
namespace Brizco.Domain.Entities.Complexes;
[AdaptTwoWays("[name]SDto", IgnoreAttributes = new[] { typeof(AdaptIgnoreAttribute) }, MapType = MapType.Map | MapType.MapToTarget | MapType.Projection)]
[AdaptTwoWays("[name]LDto", IgnoreAttributes = new[] { typeof(AdaptIgnoreAttribute) }, MapType = MapType.Map | MapType.MapToTarget)]
[AdaptTo("[name]LDto", IgnoreAttributes = new[] { typeof(AdaptIgnoreAttribute) }, MapType = MapType.Projection)]
[GenerateMapper]
public partial class Complex : ApiEntity
{
public Complex()
{
}
public Complex(string name , string address,string supportPhone)
{
Name = name;
Address = address;
SupportPhone = supportPhone;
}
public string Name { get; internal set; } = string.Empty;
public string Address { get; internal set; } = string.Empty;
public string SupportPhone { get; internal set; } = string.Empty;
public List<ApplicationRole> Roles { get; internal set; } = new();
public List<Task> Tasks { get; internal set; } = new();
public List<Shift> Shifts { get; internal set; } = new();
public List<ComplexUser> Users { get; internal set; } = new();
}