feat(dal): Созданы таблицы JobGroupTypes+UnitsInTemplates, обновлен ключ уникального индекса шаблонов
This commit is contained in:
@@ -83,6 +83,8 @@ namespace PARR.DAL.Context
|
||||
|
||||
public DbSet<UnitInUnit> UnitInUnits { get; set; }
|
||||
|
||||
public DbSet<UnitsInTemplate> UnitsInTemplates { get; set; }
|
||||
|
||||
#endregion
|
||||
|
||||
#region Job
|
||||
@@ -95,6 +97,8 @@ namespace PARR.DAL.Context
|
||||
|
||||
public DbSet<JobGroup> JobGroups { get; set; }
|
||||
|
||||
public DbSet<JobGroupType> JobGroupTypes { get; set; }
|
||||
|
||||
public DbSet<JobRelationshipFilter> JobRelationshipFilters { get; set; }
|
||||
|
||||
|
||||
@@ -119,6 +123,22 @@ namespace PARR.DAL.Context
|
||||
});
|
||||
#endregion
|
||||
|
||||
#region UnitsInTemplate
|
||||
modelBuilder.Entity<UnitsInTemplate>()
|
||||
.HasKey(t => new { t.TemplateId, t.UnitId });
|
||||
#endregion
|
||||
|
||||
#region JobGroupType
|
||||
modelBuilder.Entity<JobGroupType>(f =>
|
||||
{
|
||||
f.HasData(
|
||||
new() { Id = new Guid("4FA62E79-86BB-47C2-BE1A-72A716A170FA"), DateCreated = dateCreated, DateModified = null, Name = JobGroupTypesEnum.Simple.ToString(), Code = JobGroupTypesEnum.Simple },
|
||||
new() { Id = new Guid("6EC58B1A-5C40-47B9-B036-4FA490E8D503"), DateCreated = dateCreated, DateModified = null, Name = JobGroupTypesEnum.Umbrella.ToString(), Code = JobGroupTypesEnum.Umbrella },
|
||||
new() { Id = new Guid("318625E5-F833-436A-99DF-2A382A1E71C7"), DateCreated = dateCreated, DateModified = null, Name = JobGroupTypesEnum.Group.ToString(), Code = JobGroupTypesEnum.Group }
|
||||
);
|
||||
});
|
||||
#endregion
|
||||
|
||||
#region ApplicationType
|
||||
modelBuilder.Entity<ApplicationType>(f =>
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user