Files
parr_api/PARR.DAL/Migrations/DataContextModelSnapshot.cs

1449 lines
55 KiB
C#
Raw Normal View History

2023-05-17 16:30:13 +10:00
// <auto-generated />
2023-05-19 15:15:52 +10:00
using System;
2023-05-17 16:30:13 +10:00
using Microsoft.EntityFrameworkCore;
using Microsoft.EntityFrameworkCore.Infrastructure;
using Microsoft.EntityFrameworkCore.Storage.ValueConversion;
using Npgsql.EntityFrameworkCore.PostgreSQL.Metadata;
using PARR.DAL.Context;
#nullable disable
namespace PARR.DAL.Migrations
{
[DbContext(typeof(DataContext))]
partial class DataContextModelSnapshot : ModelSnapshot
{
protected override void BuildModel(ModelBuilder modelBuilder)
{
#pragma warning disable 612, 618
modelBuilder
.HasAnnotation("ProductVersion", "7.0.5")
.HasAnnotation("Relational:MaxIdentifierLength", 63);
NpgsqlModelBuilderExtensions.UseIdentityByDefaultColumns(modelBuilder);
2023-05-19 15:15:52 +10:00
modelBuilder.Entity("PARR.DAL.Models.AIHIT.RawDataEK", b =>
{
b.Property<Guid>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("uuid");
b.Property<int?>("AIHID")
.HasColumnType("integer");
b.Property<string>("APPType")
.HasColumnType("text");
b.Property<string>("AdditionalInfo")
.HasColumnType("text");
b.Property<string>("CKBSServerType")
.HasColumnType("text");
b.Property<string>("CTSDirection")
.HasColumnType("text");
b.Property<string>("ClientOS")
.HasColumnType("text");
b.Property<string>("ClientSoftware")
.HasColumnType("text");
b.Property<string>("Company")
.HasColumnType("text");
b.Property<string>("CreateTime")
.HasColumnType("text");
b.Property<string>("DBType")
.HasColumnType("text");
b.Property<DateTimeOffset>("DateCreated")
.HasColumnType("timestamp with time zone");
b.Property<DateTimeOffset?>("DateModified")
.HasColumnType("timestamp with time zone");
b.Property<string>("EKCategory")
.HasColumnType("text");
b.Property<string>("EKFindCode")
.HasColumnType("text");
b.Property<string>("EKRegister")
.HasColumnType("text");
b.Property<string>("EKRevizor")
.HasColumnType("text");
b.Property<string>("EKSubCategory")
.HasColumnType("text");
b.Property<string>("EKType")
.HasColumnType("text");
b.Property<string>("EndExplotationDate")
.HasColumnType("text");
b.Property<string>("FullName")
.HasColumnType("text");
b.Property<string>("IBServerType")
.HasColumnType("text");
b.Property<string>("IP")
.HasColumnType("text");
b.Property<string>("InfrastructureServerType")
.HasColumnType("text");
b.Property<string>("IsActive")
.HasColumnType("text");
b.Property<string>("IsImportant")
.HasColumnType("text");
b.Property<char?>("IsUnreliableData")
.HasColumnType("character(1)");
b.Property<string>("Location")
.HasColumnType("text");
b.Property<string>("Metka")
.HasColumnType("text");
b.Property<string>("MonitoringServerType")
.HasColumnType("text");
b.Property<string>("NetworkName")
.HasColumnType("text");
b.Property<string>("NewEKFindCode")
.HasColumnType("text");
b.Property<string>("OSType")
.HasColumnType("text");
b.Property<string>("OldEKFindCode")
.HasColumnType("text");
b.Property<string>("PlannedTimeToRepair")
.HasColumnType("text");
b.Property<string>("Prescription")
.HasColumnType("text");
b.Property<string>("ProductCode")
.HasColumnType("text");
b.Property<string>("ResponseArea")
.HasColumnType("text");
b.Property<string>("ResponsibleByEK")
.HasColumnType("text");
b.Property<string>("ServiceCode")
.HasColumnType("text");
b.Property<string>("ShiftWorkGroup")
.HasColumnType("text");
b.Property<string>("ShortName")
.HasColumnType("text");
b.Property<string>("StartExplotationDate")
.HasColumnType("text");
b.Property<string>("Status")
.HasColumnType("text");
b.Property<string>("SysModTime")
.HasColumnType("text");
b.Property<string>("SysModUser")
.HasColumnType("text");
b.Property<string>("TargetRepairTime")
.HasColumnType("text");
b.Property<string>("WorkGroup")
.HasColumnType("text");
b.HasKey("Id");
b.ToTable("RawDataEKs", "AIHIT");
});
modelBuilder.Entity("PARR.DAL.Models.AIHIT.Setting", b =>
{
b.Property<Guid>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("uuid");
b.Property<DateTimeOffset>("DateCreated")
.HasColumnType("timestamp with time zone");
b.Property<DateTimeOffset?>("DateModified")
.HasColumnType("timestamp with time zone");
b.Property<string>("Description")
.HasColumnType("text");
b.Property<string>("Group")
.HasColumnType("text");
b.Property<string>("Name")
.IsRequired()
.HasColumnType("text");
b.Property<string>("Value")
.IsRequired()
.HasColumnType("text");
b.HasKey("Id");
b.ToTable("Settings", "AIHIT");
b.HasData(
new
{
2023-09-19 16:08:54 +10:00
Id = new Guid("b16afd06-605b-499f-9e35-a19586de96b0"),
DateCreated = new DateTimeOffset(new DateTime(2023, 5, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), new TimeSpan(0, 0, 0, 0, 0)),
2023-09-19 16:08:54 +10:00
Description = "Зона ответственности",
Group = "ResponsibleArea",
Name = "ГВЦ",
Value = "00-ГВЦ"
},
new
{
Id = new Guid("42a2ec03-da3a-45fc-971e-399910fdc5ae"),
DateCreated = new DateTimeOffset(new DateTime(2023, 5, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), new TimeSpan(0, 0, 0, 0, 0)),
Description = "Зона ответственности",
Group = "ResponsibleArea",
Name = "ОКТ",
Value = "01-ОКТ"
},
new
{
Id = new Guid("17efaf65-ae8c-45f1-b187-e6cb1bd6385b"),
DateCreated = new DateTimeOffset(new DateTime(2023, 5, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), new TimeSpan(0, 0, 0, 0, 0)),
Description = "Зона ответственности",
Group = "ResponsibleArea",
Name = "КЛГ",
Value = "10-КЛГ"
},
new
{
Id = new Guid("51270997-20f6-4a61-85ac-64f6b6dd5dc4"),
DateCreated = new DateTimeOffset(new DateTime(2023, 5, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), new TimeSpan(0, 0, 0, 0, 0)),
Description = "Зона ответственности",
Group = "ResponsibleArea",
Name = "МСК",
Value = "17-МСК"
},
new
{
Id = new Guid("b94f8c38-e78a-494e-81ba-39e4e902ffcc"),
DateCreated = new DateTimeOffset(new DateTime(2023, 5, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), new TimeSpan(0, 0, 0, 0, 0)),
Description = "Зона ответственности",
Group = "ResponsibleArea",
Name = "ГОР",
Value = "24-ГОР"
},
new
{
Id = new Guid("52ba20ea-4e7a-4500-939b-e2cff563809a"),
DateCreated = new DateTimeOffset(new DateTime(2023, 5, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), new TimeSpan(0, 0, 0, 0, 0)),
Description = "Зона ответственности",
Group = "ResponsibleArea",
Name = "СЕВ",
Value = "28-СЕВ"
},
new
{
Id = new Guid("cb9da805-29e9-4e08-b1ed-d4b374920f77"),
DateCreated = new DateTimeOffset(new DateTime(2023, 5, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), new TimeSpan(0, 0, 0, 0, 0)),
Description = "Зона ответственности",
Group = "ResponsibleArea",
Name = "СКВ",
Value = "51-СКВ"
},
new
{
Id = new Guid("1943a65c-2060-4b5f-af1f-acec74835481"),
DateCreated = new DateTimeOffset(new DateTime(2023, 5, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), new TimeSpan(0, 0, 0, 0, 0)),
Description = "Зона ответственности",
Group = "ResponsibleArea",
Name = "ЮВСТ",
Value = "58-ЮВСТ"
},
new
{
Id = new Guid("4d9ef2ee-d4fa-4d28-a93b-6f1fd0a639f9"),
DateCreated = new DateTimeOffset(new DateTime(2023, 5, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), new TimeSpan(0, 0, 0, 0, 0)),
Description = "Зона ответственности",
Group = "ResponsibleArea",
Name = "ПРИВ",
Value = "61-ПРИВ"
},
new
{
Id = new Guid("f1a54c25-a93a-4fe3-8268-afbcc435b6e9"),
DateCreated = new DateTimeOffset(new DateTime(2023, 5, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), new TimeSpan(0, 0, 0, 0, 0)),
Description = "Зона ответственности",
Group = "ResponsibleArea",
Name = "КБШ",
Value = "63-КБШ"
},
new
{
Id = new Guid("cc839c48-62bb-46a8-924c-85b5e7a3e245"),
DateCreated = new DateTimeOffset(new DateTime(2023, 5, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), new TimeSpan(0, 0, 0, 0, 0)),
Description = "Зона ответственности",
Group = "ResponsibleArea",
Name = "СВРД",
Value = "76-СВРД"
},
new
{
Id = new Guid("c98fb684-ff03-441e-a9c3-ac5071d69857"),
DateCreated = new DateTimeOffset(new DateTime(2023, 5, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), new TimeSpan(0, 0, 0, 0, 0)),
Description = "Зона ответственности",
Group = "ResponsibleArea",
Name = "ЮУР",
Value = "80-ЮУР"
},
new
{
Id = new Guid("f2684a90-6029-4476-bd3d-e713a8a228d6"),
DateCreated = new DateTimeOffset(new DateTime(2023, 5, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), new TimeSpan(0, 0, 0, 0, 0)),
Description = "Зона ответственности",
Group = "ResponsibleArea",
Name = "ЗСИБ",
Value = "83-ЗСИБ"
},
new
{
Id = new Guid("b3c73162-21ea-42f0-b0e1-3c5076176f8a"),
DateCreated = new DateTimeOffset(new DateTime(2023, 5, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), new TimeSpan(0, 0, 0, 0, 0)),
Description = "Зона ответственности",
Group = "ResponsibleArea",
Name = "КРАСН",
Value = "88-КРАСН"
},
new
{
Id = new Guid("a8cff6fd-28b7-49f2-a412-9208c10f6516"),
DateCreated = new DateTimeOffset(new DateTime(2023, 5, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), new TimeSpan(0, 0, 0, 0, 0)),
Description = "Зона ответственности",
Group = "ResponsibleArea",
Name = "ВСИБ",
Value = "92-ВСИБ"
},
new
{
Id = new Guid("50f66704-4d26-4587-bb1e-dca70c8f4b89"),
DateCreated = new DateTimeOffset(new DateTime(2023, 5, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), new TimeSpan(0, 0, 0, 0, 0)),
Description = "Зона ответственности",
Group = "ResponsibleArea",
2023-09-19 16:08:54 +10:00
Name = "ЗАБ",
Value = "94-ЗАБ"
},
new
{
Id = new Guid("1fd43634-4a06-4237-9727-edfa6f3eebe8"),
DateCreated = new DateTimeOffset(new DateTime(2023, 5, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), new TimeSpan(0, 0, 0, 0, 0)),
Description = "Зона ответственности",
Group = "ResponsibleArea",
2023-09-19 16:08:54 +10:00
Name = "ДВС",
Value = "96-ДВС"
},
new
{
Id = new Guid("77c73c0a-8e4d-4676-b6e2-6a112f20e346"),
DateCreated = new DateTimeOffset(new DateTime(2023, 5, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), new TimeSpan(0, 0, 0, 0, 0)),
Description = "Статус актуальных ЭК",
Group = "Status",
Name = "Exploitation",
Value = "3-В эксплуатации"
});
});
modelBuilder.Entity("PARR.DAL.Models.Application", b =>
2023-06-16 15:00:11 +10:00
{
b.Property<Guid>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("uuid");
b.Property<Guid>("ApplicationTypeId")
.HasColumnType("uuid");
b.Property<DateTimeOffset>("DateCreated")
.HasColumnType("timestamp with time zone");
b.Property<DateTimeOffset?>("DateModified")
.HasColumnType("timestamp with time zone");
b.Property<string>("Name")
.IsRequired()
.HasColumnType("text");
b.HasKey("Id");
b.HasIndex("ApplicationTypeId");
b.ToTable("Applications");
2023-06-16 15:00:11 +10:00
});
modelBuilder.Entity("PARR.DAL.Models.ApplicationInHost", b =>
2023-06-16 15:00:11 +10:00
{
b.Property<Guid>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("uuid");
b.Property<Guid>("ApplicationId")
.HasColumnType("uuid");
b.Property<DateTimeOffset>("DateCreated")
.HasColumnType("timestamp with time zone");
b.Property<DateTimeOffset?>("DateModified")
.HasColumnType("timestamp with time zone");
b.Property<Guid>("HostId")
.HasColumnType("uuid");
b.HasKey("Id");
b.HasIndex("ApplicationId");
b.HasIndex("HostId");
b.ToTable("ApplicationsInHost");
2023-06-16 15:00:11 +10:00
});
modelBuilder.Entity("PARR.DAL.Models.ApplicationType", b =>
2023-05-19 15:15:52 +10:00
{
b.Property<Guid>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("uuid");
b.Property<Guid?>("ApplicationTypeId")
.HasColumnType("uuid");
2023-06-16 15:00:11 +10:00
b.Property<DateTimeOffset>("DateCreated")
.HasColumnType("timestamp with time zone");
b.Property<DateTimeOffset?>("DateModified")
.HasColumnType("timestamp with time zone");
b.Property<string>("Description")
2023-06-01 12:30:38 +10:00
.HasColumnType("text");
2023-06-16 15:00:11 +10:00
b.Property<string>("Name")
.IsRequired()
2023-06-01 12:30:38 +10:00
.HasColumnType("text");
2023-06-16 15:00:11 +10:00
b.HasKey("Id");
b.HasIndex("ApplicationTypeId");
b.ToTable("ApplicationTypes");
2023-06-16 15:00:11 +10:00
b.HasData(
new
{
Id = new Guid("32c28386-6f13-4f7b-8508-be165b7fabdb"),
DateCreated = new DateTimeOffset(new DateTime(2023, 5, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), new TimeSpan(0, 0, 0, 0, 0)),
Description = "Поле СП xml АИХ ИТ",
Name = "APP"
},
new
{
Id = new Guid("7848a96c-cdee-48c1-a786-de9cb889723a"),
DateCreated = new DateTimeOffset(new DateTime(2023, 5, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), new TimeSpan(0, 0, 0, 0, 0)),
Description = "Поле ОС xml АИХ ИТ",
Name = "OS"
},
new
{
Id = new Guid("aae2636f-b93a-42dc-873e-0764a90a0a40"),
DateCreated = new DateTimeOffset(new DateTime(2023, 5, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), new TimeSpan(0, 0, 0, 0, 0)),
Description = "Поле СУБД xml АИХ ИТ",
Name = "DB"
});
});
modelBuilder.Entity("PARR.DAL.Models.ApplicationsInWork", b =>
{
b.Property<Guid>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("uuid");
b.Property<Guid>("ApplicationId")
.HasColumnType("uuid");
b.Property<DateTimeOffset>("DateCreated")
.HasColumnType("timestamp with time zone");
b.Property<DateTimeOffset?>("DateModified")
.HasColumnType("timestamp with time zone");
b.Property<string>("FullDescription")
.IsRequired()
.HasColumnType("text");
b.Property<string>("ShortDescription")
.IsRequired()
.HasColumnType("text");
b.Property<string>("Solution")
.IsRequired()
.HasColumnType("text");
b.Property<string>("TemplateDuration")
.IsRequired()
.HasColumnType("text");
b.Property<Guid>("WorkId")
.HasColumnType("uuid");
b.HasKey("Id");
b.HasIndex("ApplicationId");
b.HasIndex("WorkId", "ApplicationId")
.IsUnique();
b.ToTable("ApplicationsInWorks");
});
modelBuilder.Entity("PARR.DAL.Models.Host", b =>
{
b.Property<Guid>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("uuid");
b.Property<DateTimeOffset>("DateCreated")
.HasColumnType("timestamp with time zone");
b.Property<DateTimeOffset?>("DateModified")
.HasColumnType("timestamp with time zone");
b.Property<string>("Ek")
.IsRequired()
.HasColumnType("text");
b.Property<string>("IP")
.IsRequired()
.HasColumnType("text");
b.Property<string>("ResponseArea")
.HasColumnType("text");
b.Property<string>("Status")
.HasColumnType("text");
b.Property<string>("WorkGroup")
.HasColumnType("text");
b.HasKey("Id");
b.ToTable("Hosts");
});
modelBuilder.Entity("PARR.DAL.Models.Process", b =>
{
b.Property<Guid>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("uuid");
b.Property<DateTimeOffset>("DateCreated")
.HasColumnType("timestamp with time zone");
b.Property<DateTimeOffset?>("DateModified")
.HasColumnType("timestamp with time zone");
b.Property<int>("EsppId")
.HasColumnType("integer");
b.Property<string>("Name")
.IsRequired()
.HasColumnType("text");
b.HasKey("Id");
b.ToTable("Processes");
});
modelBuilder.Entity("PARR.DAL.Models.Setting", b =>
{
b.Property<string>("Name")
.HasColumnType("text");
b.Property<string>("Description")
.IsRequired()
.HasColumnType("text");
b.Property<string>("Value")
.IsRequired()
.HasColumnType("text");
b.HasKey("Name");
2023-09-19 14:40:25 +10:00
b.ToTable("Settings");
b.HasData(
new
{
Name = "Initiator",
Description = "Инициатор регламентной работы, указывается при создании шаблона в ЕСПП.",
2023-09-19 14:34:55 +10:00
Value = "КУЗНЕЦОВ МИХАИЛ ВАЛЕРЬЕВИЧ (IVC_KUZNETSOVMV@DVGD.OAO.RZD)"
},
new
{
Name = "ClosingCode",
Description = "Код закрытия регламентной работы, указывается при создании шаблона в ЕСПП.",
Value = "выполнен"
},
new
{
Name = "Category",
Description = "Категория создаваемого объекта в ЕСПП",
Value = "регламентная работа"
},
new
{
Name = "TemplatePrefixName",
Description = "Префикс имени шаблона в ЕСПП",
Value = "ПАРР-ДВС-ПТК__"
});
});
modelBuilder.Entity("PARR.DAL.Models.StatusTemplate", b =>
{
b.Property<int>("Code")
.ValueGeneratedOnAdd()
.HasColumnType("integer");
NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property<int>("Code"));
b.Property<string>("Description")
.IsRequired()
.HasColumnType("text");
b.Property<string>("Name")
.IsRequired()
.HasColumnType("text");
b.HasKey("Code");
b.ToTable("StatusTemplates");
b.HasData(
new
{
Code = 10,
Description = "Создали шаблон в ПАРР",
Name = "Creating"
},
new
{
Code = 20,
Description = "Выявлено несоответствие. Требуется привлечение робота",
Name = "Updating"
},
new
{
Code = 30,
Description = "Нормальное состояние шаблона в ЕСПП и ПАРР. Шаблон в ПАРР соответствует шаблону в ЕСПП",
Name = "Ok"
});
});
modelBuilder.Entity("PARR.DAL.Models.Subprocess", b =>
{
b.Property<Guid>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("uuid");
b.Property<DateTimeOffset>("DateCreated")
.HasColumnType("timestamp with time zone");
b.Property<DateTimeOffset?>("DateModified")
.HasColumnType("timestamp with time zone");
b.Property<int>("EsppId")
.HasColumnType("integer");
b.Property<string>("Name")
.IsRequired()
.HasColumnType("text");
b.Property<Guid>("ProcessId")
.HasColumnType("uuid");
b.HasKey("Id");
b.HasIndex("ProcessId");
b.ToTable("Subprocesses");
});
2023-09-01 12:40:41 +10:00
modelBuilder.Entity("PARR.DAL.Models.Template", b =>
{
b.Property<Guid>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("uuid");
b.Property<Guid>("ApplicationInWorkId")
.HasColumnType("uuid");
2023-09-01 12:40:41 +10:00
b.Property<DateTimeOffset>("DateCreated")
.HasColumnType("timestamp with time zone");
b.Property<DateTimeOffset?>("DateModified")
.HasColumnType("timestamp with time zone");
b.Property<Guid>("HostId")
.HasColumnType("uuid");
b.Property<bool>("IsActive")
.HasColumnType("boolean");
b.Property<string>("Name")
.IsRequired()
.HasColumnType("text");
2023-09-01 12:40:41 +10:00
b.Property<int>("StatusCode")
.HasColumnType("integer");
2023-09-01 12:40:41 +10:00
b.HasKey("Id");
b.HasIndex("ApplicationInWorkId");
b.HasIndex("HostId");
b.HasIndex("Name")
.IsUnique();
b.HasIndex("StatusCode");
2023-09-01 12:40:41 +10:00
b.ToTable("Templates");
});
modelBuilder.Entity("PARR.DAL.Models.Tnk", b =>
{
b.Property<Guid>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("uuid");
b.Property<DateTimeOffset>("DateCreated")
.HasColumnType("timestamp with time zone");
b.Property<DateTimeOffset?>("DateModified")
.HasColumnType("timestamp with time zone");
b.Property<int>("EsppId")
.HasColumnType("integer");
b.Property<string>("Name")
.IsRequired()
.HasColumnType("text");
b.Property<Guid>("SubprocessId")
.HasColumnType("uuid");
b.HasKey("Id");
b.HasIndex("SubprocessId");
b.ToTable("Tnks");
});
modelBuilder.Entity("PARR.DAL.Models.V1.V1_Application", b =>
{
b.Property<Guid>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("uuid");
b.Property<Guid>("ApplicationTypeId")
.HasColumnType("uuid");
b.Property<DateTimeOffset>("DateCreated")
.HasColumnType("timestamp with time zone");
b.Property<DateTimeOffset?>("DateModified")
.HasColumnType("timestamp with time zone");
b.Property<string>("Name")
.IsRequired()
.HasColumnType("text");
b.HasKey("Id");
b.HasIndex("ApplicationTypeId");
b.ToTable("V1_Applications");
});
modelBuilder.Entity("PARR.DAL.Models.V1.V1_ApplicationInHost", b =>
{
b.Property<Guid>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("uuid");
b.Property<Guid>("ApplicationId")
.HasColumnType("uuid");
b.Property<DateTimeOffset>("DateCreated")
.HasColumnType("timestamp with time zone");
b.Property<DateTimeOffset?>("DateModified")
.HasColumnType("timestamp with time zone");
b.Property<Guid>("HostId")
.HasColumnType("uuid");
b.Property<Guid?>("V1_ApplicationId")
.HasColumnType("uuid");
b.HasKey("Id");
b.HasIndex("ApplicationId");
b.HasIndex("HostId");
b.HasIndex("V1_ApplicationId");
b.ToTable("V1_ApplicationsInHost");
});
modelBuilder.Entity("PARR.DAL.Models.V1.V1_ApplicationType", b =>
{
b.Property<Guid>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("uuid");
b.Property<DateTimeOffset>("DateCreated")
.HasColumnType("timestamp with time zone");
b.Property<DateTimeOffset?>("DateModified")
.HasColumnType("timestamp with time zone");
b.Property<string>("Description")
.HasColumnType("text");
b.Property<string>("Name")
.IsRequired()
.HasColumnType("text");
b.Property<Guid?>("V1_ApplicationTypeId")
.HasColumnType("uuid");
b.HasKey("Id");
b.HasIndex("V1_ApplicationTypeId");
b.ToTable("V1_ApplicationTypes");
});
modelBuilder.Entity("PARR.DAL.Models.V1.V1_Host", b =>
2023-06-16 15:00:11 +10:00
{
b.Property<Guid>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("uuid");
2023-05-19 15:15:52 +10:00
b.Property<DateTimeOffset>("DateCreated")
.HasColumnType("timestamp with time zone");
b.Property<DateTimeOffset?>("DateModified")
.HasColumnType("timestamp with time zone");
b.Property<string>("HostName")
.HasColumnType("text");
b.Property<string>("IP")
.IsRequired()
.HasColumnType("text");
2023-06-01 12:30:38 +10:00
b.Property<string>("LinkEK")
.HasColumnType("text");
b.Property<string>("RegionalEK")
.HasColumnType("text");
b.Property<string>("Responsible")
.HasColumnType("text");
b.Property<string>("Status")
.HasColumnType("text");
b.Property<string>("WorkGroup")
.HasColumnType("text");
2023-05-19 15:15:52 +10:00
b.HasKey("Id");
b.ToTable("V1_Hosts");
2023-05-19 15:15:52 +10:00
});
modelBuilder.Entity("PARR.DAL.Models.V1.V1_Job", b =>
2023-05-19 15:15:52 +10:00
{
b.Property<Guid>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("uuid");
2023-06-16 15:00:11 +10:00
b.Property<Guid>("ApplicationId")
.HasColumnType("uuid");
2023-05-19 15:15:52 +10:00
b.Property<DateTimeOffset>("DateCreated")
.HasColumnType("timestamp with time zone");
b.Property<DateTimeOffset?>("DateModified")
.HasColumnType("timestamp with time zone");
2023-06-20 12:29:58 +10:00
b.Property<int>("Frequency")
.HasColumnType("integer");
b.Property<bool>("IsEnabled")
.HasColumnType("boolean");
2023-06-16 15:00:11 +10:00
b.Property<Guid?>("JobCategoryId")
2023-05-19 15:15:52 +10:00
.HasColumnType("uuid");
b.Property<Guid>("JobModeId")
.HasColumnType("uuid");
b.Property<Guid?>("JobTypeId")
2023-05-19 15:15:52 +10:00
.HasColumnType("uuid");
b.Property<string>("Name")
.IsRequired()
.HasColumnType("text");
2023-06-16 15:00:11 +10:00
b.Property<string>("ScriptName")
.IsRequired()
.HasColumnType("text");
2023-06-20 12:29:58 +10:00
b.Property<DateTimeOffset>("StartAt")
.HasColumnType("timestamp with time zone");
2023-05-19 15:15:52 +10:00
b.HasKey("Id");
2023-06-16 15:00:11 +10:00
b.HasIndex("ApplicationId");
2023-05-19 15:15:52 +10:00
b.HasIndex("JobCategoryId");
b.HasIndex("JobModeId");
b.HasIndex("JobTypeId");
b.ToTable("V1_Jobs");
2023-05-19 15:15:52 +10:00
});
modelBuilder.Entity("PARR.DAL.Models.V1.V1_JobCategory", b =>
2023-05-19 15:15:52 +10:00
{
b.Property<Guid>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("uuid");
b.Property<DateTimeOffset>("DateCreated")
.HasColumnType("timestamp with time zone");
b.Property<DateTimeOffset?>("DateModified")
.HasColumnType("timestamp with time zone");
b.Property<string>("Description")
.HasColumnType("text");
b.Property<string>("Name")
.IsRequired()
.HasColumnType("text");
b.HasKey("Id");
b.ToTable("V1_JobCategorys");
2023-05-19 15:15:52 +10:00
});
modelBuilder.Entity("PARR.DAL.Models.V1.V1_JobJournal", b =>
2023-05-19 15:15:52 +10:00
{
b.Property<Guid>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("uuid");
b.Property<DateTimeOffset>("DateCreated")
.HasColumnType("timestamp with time zone");
b.Property<DateTimeOffset?>("DateModified")
.HasColumnType("timestamp with time zone");
b.Property<DateTimeOffset>("DateOper")
.HasColumnType("timestamp with time zone");
2023-05-19 15:15:52 +10:00
b.Property<Guid>("HostId")
.HasColumnType("uuid");
b.Property<string>("Info")
.HasColumnType("text");
b.Property<Guid>("JobId")
.HasColumnType("uuid");
b.Property<Guid>("JobStatusId")
.HasColumnType("uuid");
b.Property<string>("Other")
.HasColumnType("text");
b.Property<int?>("TimeOut")
.HasColumnType("integer");
b.HasKey("Id");
b.HasIndex("HostId");
b.HasIndex("JobId");
b.HasIndex("JobStatusId");
b.ToTable("V1_JobJournals");
2023-05-19 15:15:52 +10:00
});
modelBuilder.Entity("PARR.DAL.Models.V1.V1_JobMode", b =>
2023-05-19 15:15:52 +10:00
{
b.Property<Guid>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("uuid");
b.Property<DateTimeOffset>("DateCreated")
.HasColumnType("timestamp with time zone");
b.Property<DateTimeOffset?>("DateModified")
.HasColumnType("timestamp with time zone");
b.Property<string>("Name")
.IsRequired()
.HasColumnType("text");
b.HasKey("Id");
b.ToTable("V1_JobModes");
2023-06-16 15:00:11 +10:00
b.HasData(
new
{
Id = new Guid("fba4202c-5bad-49c4-b076-d1ca6e1fb158"),
DateCreated = new DateTimeOffset(new DateTime(2023, 5, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), new TimeSpan(0, 0, 0, 0, 0)),
Name = "auto"
},
new
{
Id = new Guid("7516b952-510d-4aaa-971c-a14b184fc1d5"),
DateCreated = new DateTimeOffset(new DateTime(2023, 5, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), new TimeSpan(0, 0, 0, 0, 0)),
Name = "manual"
});
2023-05-19 15:15:52 +10:00
});
modelBuilder.Entity("PARR.DAL.Models.V1.V1_JobStatus", b =>
2023-05-19 15:15:52 +10:00
{
b.Property<Guid>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("uuid");
b.Property<DateTimeOffset>("DateCreated")
.HasColumnType("timestamp with time zone");
b.Property<DateTimeOffset?>("DateModified")
.HasColumnType("timestamp with time zone");
b.Property<string>("Description")
.HasColumnType("text");
b.Property<string>("Name")
.IsRequired()
.HasColumnType("text");
b.HasKey("Id");
b.ToTable("V1_JobStatuses");
2023-06-20 12:29:58 +10:00
b.HasData(
new
{
Id = new Guid("edef6dc3-adad-4c77-8ad1-63bb9052355a"),
DateCreated = new DateTimeOffset(new DateTime(2023, 5, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), new TimeSpan(0, 0, 0, 0, 0)),
Description = "Задание запущено",
Name = "started"
},
new
{
Id = new Guid("7b945eb6-d885-4570-aff5-8866f1f75ff2"),
DateCreated = new DateTimeOffset(new DateTime(2023, 5, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), new TimeSpan(0, 0, 0, 0, 0)),
Description = "Задание выполнено",
Name = "finished"
});
2023-05-19 15:15:52 +10:00
});
modelBuilder.Entity("PARR.DAL.Models.V1.V1_JobType", b =>
2023-05-19 15:15:52 +10:00
{
b.Property<Guid>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("uuid");
b.Property<DateTimeOffset>("DateCreated")
.HasColumnType("timestamp with time zone");
b.Property<DateTimeOffset?>("DateModified")
.HasColumnType("timestamp with time zone");
b.Property<string>("Description")
.HasColumnType("text");
b.Property<string>("Name")
.IsRequired()
.HasColumnType("text");
b.HasKey("Id");
b.ToTable("V1_JobTypes");
2023-05-19 15:15:52 +10:00
});
modelBuilder.Entity("PARR.DAL.Models.Work", b =>
{
b.Property<Guid>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("uuid");
b.Property<DateTimeOffset>("DateCreated")
.HasColumnType("timestamp with time zone");
b.Property<DateTimeOffset?>("DateModified")
.HasColumnType("timestamp with time zone");
b.Property<int>("EsppId")
.HasColumnType("integer");
b.Property<string>("Name")
.IsRequired()
.HasColumnType("text");
b.Property<Guid>("TnkId")
.HasColumnType("uuid");
b.HasKey("Id");
b.HasIndex("TnkId");
b.ToTable("Works");
});
modelBuilder.Entity("PARR.DAL.Models.Application", b =>
{
b.HasOne("PARR.DAL.Models.ApplicationType", "ApplicationType")
.WithMany()
.HasForeignKey("ApplicationTypeId")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
b.Navigation("ApplicationType");
});
modelBuilder.Entity("PARR.DAL.Models.ApplicationInHost", b =>
{
b.HasOne("PARR.DAL.Models.Application", "Application")
.WithMany("ApplicationsInHosts")
.HasForeignKey("ApplicationId")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
b.HasOne("PARR.DAL.Models.Host", "Host")
.WithMany("ApplicationsInHosts")
.HasForeignKey("HostId")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
b.Navigation("Application");
b.Navigation("Host");
});
modelBuilder.Entity("PARR.DAL.Models.ApplicationType", b =>
{
b.HasOne("PARR.DAL.Models.ApplicationType", null)
.WithMany("ApplicationTypes")
.HasForeignKey("ApplicationTypeId");
});
modelBuilder.Entity("PARR.DAL.Models.ApplicationsInWork", b =>
{
b.HasOne("PARR.DAL.Models.Application", "Application")
.WithMany("ApplicationsInWorks")
.HasForeignKey("ApplicationId")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
b.HasOne("PARR.DAL.Models.Work", "Work")
.WithMany("ApplicationsInWorks")
.HasForeignKey("WorkId")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
b.Navigation("Application");
b.Navigation("Work");
});
modelBuilder.Entity("PARR.DAL.Models.Subprocess", b =>
{
b.HasOne("PARR.DAL.Models.Process", "Process")
.WithMany("Subprocesses")
.HasForeignKey("ProcessId")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
b.Navigation("Process");
});
modelBuilder.Entity("PARR.DAL.Models.Template", b =>
{
b.HasOne("PARR.DAL.Models.ApplicationsInWork", "ApplicationsInWork")
.WithMany("Templates")
.HasForeignKey("ApplicationInWorkId")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
b.HasOne("PARR.DAL.Models.Host", "Host")
2023-09-20 09:52:51 +10:00
.WithMany("Templates")
.HasForeignKey("HostId")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
b.HasOne("PARR.DAL.Models.StatusTemplate", "StatusTemplate")
.WithMany("Templates")
.HasForeignKey("StatusCode")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
b.Navigation("ApplicationsInWork");
b.Navigation("Host");
b.Navigation("StatusTemplate");
});
modelBuilder.Entity("PARR.DAL.Models.Tnk", b =>
{
b.HasOne("PARR.DAL.Models.Subprocess", "Subprocess")
.WithMany("Tnks")
.HasForeignKey("SubprocessId")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
b.Navigation("Subprocess");
});
modelBuilder.Entity("PARR.DAL.Models.V1.V1_Application", b =>
2023-06-16 15:00:11 +10:00
{
b.HasOne("PARR.DAL.Models.V1.V1_ApplicationType", "ApplicationType")
2023-06-16 15:00:11 +10:00
.WithMany()
.HasForeignKey("ApplicationTypeId")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
b.Navigation("ApplicationType");
});
modelBuilder.Entity("PARR.DAL.Models.V1.V1_ApplicationInHost", b =>
2023-06-16 15:00:11 +10:00
{
b.HasOne("PARR.DAL.Models.Application", "Application")
.WithMany()
2023-06-16 15:00:11 +10:00
.HasForeignKey("ApplicationId")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
b.HasOne("PARR.DAL.Models.V1.V1_Host", "Host")
2023-06-16 15:00:11 +10:00
.WithMany("ApplicationsInHosts")
.HasForeignKey("HostId")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
b.HasOne("PARR.DAL.Models.V1.V1_Application", null)
.WithMany("V1_ApplicationsInHosts")
.HasForeignKey("V1_ApplicationId");
2023-06-16 15:00:11 +10:00
b.Navigation("Application");
b.Navigation("Host");
});
modelBuilder.Entity("PARR.DAL.Models.V1.V1_ApplicationType", b =>
{
b.HasOne("PARR.DAL.Models.V1.V1_ApplicationType", null)
.WithMany("V1_ApplicationTypes")
.HasForeignKey("V1_ApplicationTypeId");
});
modelBuilder.Entity("PARR.DAL.Models.V1.V1_Job", b =>
2023-05-19 15:15:52 +10:00
{
b.HasOne("PARR.DAL.Models.Application", "Application")
2023-06-16 15:00:11 +10:00
.WithMany()
.HasForeignKey("ApplicationId")
2023-05-19 15:15:52 +10:00
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
b.HasOne("PARR.DAL.Models.V1.V1_JobCategory", "JobCategorye")
2023-06-16 15:00:11 +10:00
.WithMany("Jobs")
.HasForeignKey("JobCategoryId");
b.HasOne("PARR.DAL.Models.V1.V1_JobMode", "JobMode")
2023-05-19 15:15:52 +10:00
.WithMany("Jobs")
.HasForeignKey("JobModeId")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
b.HasOne("PARR.DAL.Models.V1.V1_JobType", "JobType")
2023-05-19 15:15:52 +10:00
.WithMany("Jobs")
.HasForeignKey("JobTypeId");
2023-05-19 15:15:52 +10:00
2023-06-16 15:00:11 +10:00
b.Navigation("Application");
2023-05-19 15:15:52 +10:00
b.Navigation("JobCategorye");
2023-06-16 15:00:11 +10:00
b.Navigation("JobMode");
2023-05-19 15:15:52 +10:00
b.Navigation("JobType");
});
modelBuilder.Entity("PARR.DAL.Models.V1.V1_JobJournal", b =>
2023-05-19 15:15:52 +10:00
{
b.HasOne("PARR.DAL.Models.V1.V1_Host", "Host")
2023-05-19 15:15:52 +10:00
.WithMany("JobJournals")
.HasForeignKey("HostId")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
b.HasOne("PARR.DAL.Models.V1.V1_Job", "Job")
2023-05-19 15:15:52 +10:00
.WithMany("Journals")
.HasForeignKey("JobId")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
b.HasOne("PARR.DAL.Models.V1.V1_JobStatus", "Status")
2023-05-19 15:15:52 +10:00
.WithMany("Journals")
.HasForeignKey("JobStatusId")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
b.Navigation("Host");
b.Navigation("Job");
b.Navigation("Status");
});
modelBuilder.Entity("PARR.DAL.Models.Work", b =>
{
b.HasOne("PARR.DAL.Models.Tnk", "Tnk")
.WithMany("Works")
.HasForeignKey("TnkId")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
b.Navigation("Tnk");
});
modelBuilder.Entity("PARR.DAL.Models.Application", b =>
2023-06-16 15:00:11 +10:00
{
b.Navigation("ApplicationsInHosts");
b.Navigation("ApplicationsInWorks");
2023-06-16 15:00:11 +10:00
});
modelBuilder.Entity("PARR.DAL.Models.ApplicationType", b =>
{
b.Navigation("ApplicationTypes");
});
modelBuilder.Entity("PARR.DAL.Models.ApplicationsInWork", b =>
{
b.Navigation("Templates");
});
modelBuilder.Entity("PARR.DAL.Models.Host", b =>
{
b.Navigation("ApplicationsInHosts");
2023-09-20 09:52:51 +10:00
b.Navigation("Templates");
});
modelBuilder.Entity("PARR.DAL.Models.Process", b =>
{
b.Navigation("Subprocesses");
});
modelBuilder.Entity("PARR.DAL.Models.StatusTemplate", b =>
{
b.Navigation("Templates");
});
modelBuilder.Entity("PARR.DAL.Models.Subprocess", b =>
{
b.Navigation("Tnks");
});
modelBuilder.Entity("PARR.DAL.Models.Tnk", b =>
{
b.Navigation("Works");
});
modelBuilder.Entity("PARR.DAL.Models.V1.V1_Application", b =>
{
b.Navigation("V1_ApplicationsInHosts");
});
modelBuilder.Entity("PARR.DAL.Models.V1.V1_ApplicationType", b =>
{
b.Navigation("V1_ApplicationTypes");
});
modelBuilder.Entity("PARR.DAL.Models.V1.V1_Host", b =>
2023-05-19 15:15:52 +10:00
{
2023-06-16 15:00:11 +10:00
b.Navigation("ApplicationsInHosts");
2023-05-19 15:15:52 +10:00
b.Navigation("JobJournals");
});
modelBuilder.Entity("PARR.DAL.Models.V1.V1_Job", b =>
2023-05-19 15:15:52 +10:00
{
b.Navigation("Journals");
});
modelBuilder.Entity("PARR.DAL.Models.V1.V1_JobCategory", b =>
2023-05-19 15:15:52 +10:00
{
b.Navigation("Jobs");
});
modelBuilder.Entity("PARR.DAL.Models.V1.V1_JobMode", b =>
2023-05-19 15:15:52 +10:00
{
b.Navigation("Jobs");
});
modelBuilder.Entity("PARR.DAL.Models.V1.V1_JobStatus", b =>
2023-05-19 15:15:52 +10:00
{
b.Navigation("Journals");
});
modelBuilder.Entity("PARR.DAL.Models.V1.V1_JobType", b =>
2023-05-19 15:15:52 +10:00
{
b.Navigation("Jobs");
});
modelBuilder.Entity("PARR.DAL.Models.Work", b =>
{
b.Navigation("ApplicationsInWorks");
});
2023-05-17 16:30:13 +10:00
#pragma warning restore 612, 618
}
}
}