2021-09-07 14:04:30 +05:00
|
|
|
|
// <auto-generated />
|
|
|
|
|
using System;
|
|
|
|
|
using System.Collections.Generic;
|
|
|
|
|
using AsbCloudDb.Model;
|
|
|
|
|
using Microsoft.EntityFrameworkCore;
|
|
|
|
|
using Microsoft.EntityFrameworkCore.Infrastructure;
|
|
|
|
|
using Microsoft.EntityFrameworkCore.Storage.ValueConversion;
|
|
|
|
|
using Npgsql.EntityFrameworkCore.PostgreSQL.Metadata;
|
|
|
|
|
|
|
|
|
|
namespace AsbCloudDb.Migrations
|
|
|
|
|
{
|
|
|
|
|
[DbContext(typeof(AsbCloudDbContext))]
|
|
|
|
|
partial class AsbCloudDbContextModelSnapshot : ModelSnapshot
|
|
|
|
|
{
|
|
|
|
|
protected override void BuildModel(ModelBuilder modelBuilder)
|
|
|
|
|
{
|
|
|
|
|
#pragma warning disable 612, 618
|
|
|
|
|
modelBuilder
|
|
|
|
|
.HasPostgresExtension("adminpack")
|
|
|
|
|
.HasAnnotation("Relational:Collation", "Russian_Russia.1251")
|
|
|
|
|
.HasAnnotation("Relational:MaxIdentifierLength", 63)
|
2021-10-01 17:37:44 +05:00
|
|
|
|
.HasAnnotation("ProductVersion", "5.0.10")
|
|
|
|
|
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
2021-09-07 14:04:30 +05:00
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("AsbCloudDb.Model.Cluster", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Property<int>("Id")
|
|
|
|
|
.ValueGeneratedOnAdd()
|
|
|
|
|
.HasColumnType("integer")
|
|
|
|
|
.HasColumnName("id")
|
2021-10-01 17:37:44 +05:00
|
|
|
|
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
2021-09-07 14:04:30 +05:00
|
|
|
|
|
|
|
|
|
b.Property<string>("Caption")
|
|
|
|
|
.HasMaxLength(255)
|
|
|
|
|
.HasColumnType("character varying(255)")
|
|
|
|
|
.HasColumnName("caption")
|
|
|
|
|
.HasComment("Название");
|
|
|
|
|
|
|
|
|
|
b.Property<int?>("IdDeposit")
|
|
|
|
|
.HasColumnType("integer")
|
|
|
|
|
.HasColumnName("id_deposit");
|
|
|
|
|
|
|
|
|
|
b.Property<double?>("Latitude")
|
|
|
|
|
.HasColumnType("double precision")
|
|
|
|
|
.HasColumnName("latitude");
|
|
|
|
|
|
|
|
|
|
b.Property<double?>("Longitude")
|
|
|
|
|
.HasColumnType("double precision")
|
|
|
|
|
.HasColumnName("longitude");
|
|
|
|
|
|
|
|
|
|
b.HasKey("Id");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("IdDeposit");
|
|
|
|
|
|
|
|
|
|
b.ToTable("t_cluster");
|
|
|
|
|
|
|
|
|
|
b
|
|
|
|
|
.HasComment("Кусты");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("AsbCloudDb.Model.Company", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Property<int>("Id")
|
|
|
|
|
.ValueGeneratedOnAdd()
|
|
|
|
|
.HasColumnType("integer")
|
|
|
|
|
.HasColumnName("id")
|
2021-10-01 17:37:44 +05:00
|
|
|
|
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
2021-09-07 14:04:30 +05:00
|
|
|
|
|
|
|
|
|
b.Property<string>("Caption")
|
|
|
|
|
.HasMaxLength(255)
|
|
|
|
|
.HasColumnType("character varying(255)")
|
|
|
|
|
.HasColumnName("caption");
|
|
|
|
|
|
|
|
|
|
b.Property<int>("IdCompanyType")
|
|
|
|
|
.HasMaxLength(255)
|
|
|
|
|
.HasColumnType("integer")
|
|
|
|
|
.HasColumnName("id_company_type")
|
|
|
|
|
.HasComment("вид деятельности");
|
|
|
|
|
|
|
|
|
|
b.HasKey("Id");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("IdCompanyType");
|
|
|
|
|
|
|
|
|
|
b.ToTable("t_company");
|
|
|
|
|
|
|
|
|
|
b.HasData(
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 1,
|
|
|
|
|
Caption = "ООО \"АСБ\"",
|
|
|
|
|
IdCompanyType = 3
|
|
|
|
|
});
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("AsbCloudDb.Model.CompanyType", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Property<int>("Id")
|
|
|
|
|
.ValueGeneratedOnAdd()
|
|
|
|
|
.HasColumnType("integer")
|
|
|
|
|
.HasColumnName("id")
|
2021-10-01 17:37:44 +05:00
|
|
|
|
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
2021-09-07 14:04:30 +05:00
|
|
|
|
|
|
|
|
|
b.Property<string>("Caption")
|
|
|
|
|
.HasMaxLength(255)
|
|
|
|
|
.HasColumnType("character varying(255)")
|
|
|
|
|
.HasColumnName("caption");
|
|
|
|
|
|
|
|
|
|
b.HasKey("Id");
|
|
|
|
|
|
|
|
|
|
b.ToTable("t_company_type");
|
|
|
|
|
|
|
|
|
|
b.HasData(
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 1,
|
|
|
|
|
Caption = "Недрапользователь"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 2,
|
|
|
|
|
Caption = "Буровой подрядчик"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 3,
|
|
|
|
|
Caption = "Сервис автоматизации бурения"
|
|
|
|
|
});
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("AsbCloudDb.Model.Deposit", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Property<int>("Id")
|
|
|
|
|
.ValueGeneratedOnAdd()
|
|
|
|
|
.HasColumnType("integer")
|
|
|
|
|
.HasColumnName("id")
|
2021-10-01 17:37:44 +05:00
|
|
|
|
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
2021-09-07 14:04:30 +05:00
|
|
|
|
|
|
|
|
|
b.Property<string>("Caption")
|
|
|
|
|
.HasMaxLength(255)
|
|
|
|
|
.HasColumnType("character varying(255)")
|
|
|
|
|
.HasColumnName("caption");
|
|
|
|
|
|
|
|
|
|
b.Property<double?>("Latitude")
|
|
|
|
|
.HasColumnType("double precision")
|
|
|
|
|
.HasColumnName("latitude");
|
|
|
|
|
|
|
|
|
|
b.Property<double?>("Longitude")
|
|
|
|
|
.HasColumnType("double precision")
|
|
|
|
|
.HasColumnName("longitude");
|
|
|
|
|
|
|
|
|
|
b.HasKey("Id");
|
|
|
|
|
|
|
|
|
|
b.ToTable("t_deposit");
|
|
|
|
|
|
|
|
|
|
b
|
|
|
|
|
.HasComment("Месторождение");
|
|
|
|
|
});
|
|
|
|
|
|
2021-10-14 14:46:20 +05:00
|
|
|
|
modelBuilder.Entity("AsbCloudDb.Model.DrillFlowChart", b =>
|
2021-10-13 17:34:32 +05:00
|
|
|
|
{
|
|
|
|
|
b.Property<int>("Id")
|
|
|
|
|
.ValueGeneratedOnAdd()
|
|
|
|
|
.HasColumnType("integer")
|
|
|
|
|
.HasColumnName("id")
|
|
|
|
|
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
|
|
|
|
|
|
|
|
|
b.Property<double>("AxialLoadMax")
|
|
|
|
|
.HasColumnType("double precision")
|
|
|
|
|
.HasColumnName("axial_load_max")
|
|
|
|
|
.HasComment("Максимальная нагрузка");
|
|
|
|
|
|
|
|
|
|
b.Property<double>("AxialLoadMin")
|
|
|
|
|
.HasColumnType("double precision")
|
|
|
|
|
.HasColumnName("axial_load_min")
|
|
|
|
|
.HasComment("Минимальная нагрузка");
|
|
|
|
|
|
|
|
|
|
b.Property<double>("DepthEnd")
|
|
|
|
|
.HasColumnType("double precision")
|
|
|
|
|
.HasColumnName("depth_end")
|
|
|
|
|
.HasComment("Глубина окончания интервала");
|
|
|
|
|
|
|
|
|
|
b.Property<double>("DepthStart")
|
|
|
|
|
.HasColumnType("double precision")
|
|
|
|
|
.HasColumnName("depth_start")
|
|
|
|
|
.HasComment("Стартовая глубина");
|
|
|
|
|
|
|
|
|
|
b.Property<double>("FlowMax")
|
|
|
|
|
.HasColumnType("double precision")
|
|
|
|
|
.HasColumnName("flow_max")
|
|
|
|
|
.HasComment("Максимальный расход");
|
|
|
|
|
|
|
|
|
|
b.Property<double>("FlowMin")
|
|
|
|
|
.HasColumnType("double precision")
|
|
|
|
|
.HasColumnName("flow_min")
|
|
|
|
|
.HasComment("Минимальный расход");
|
|
|
|
|
|
|
|
|
|
b.Property<int>("IdWell")
|
|
|
|
|
.HasColumnType("integer")
|
|
|
|
|
.HasColumnName("well_id")
|
|
|
|
|
.HasComment("Id скважины");
|
|
|
|
|
|
2021-10-14 17:02:20 +05:00
|
|
|
|
b.Property<int>("IdWellOperationCategory")
|
|
|
|
|
.HasColumnType("integer")
|
|
|
|
|
.HasColumnName("id_operation_category")
|
|
|
|
|
.HasComment("Id типа операции");
|
|
|
|
|
|
2021-10-13 17:34:32 +05:00
|
|
|
|
b.Property<DateTime>("LastUpdate")
|
|
|
|
|
.HasColumnType("timestamp without time zone")
|
|
|
|
|
.HasColumnName("last_update")
|
|
|
|
|
.HasComment("Дата последнего изменения");
|
|
|
|
|
|
|
|
|
|
b.Property<double>("PressureMax")
|
|
|
|
|
.HasColumnType("double precision")
|
|
|
|
|
.HasColumnName("pressure_max")
|
|
|
|
|
.HasComment("Максимальное давление");
|
|
|
|
|
|
|
|
|
|
b.Property<double>("PressureMin")
|
|
|
|
|
.HasColumnType("double precision")
|
|
|
|
|
.HasColumnName("pressure_min")
|
|
|
|
|
.HasComment("Минимальное давление");
|
|
|
|
|
|
|
|
|
|
b.Property<double>("RotorSpeedMax")
|
|
|
|
|
.HasColumnType("double precision")
|
|
|
|
|
.HasColumnName("rotor_speed_max")
|
|
|
|
|
.HasComment("Максимальные обороты на ВСП");
|
|
|
|
|
|
|
|
|
|
b.Property<double>("RotorSpeedMin")
|
|
|
|
|
.HasColumnType("double precision")
|
|
|
|
|
.HasColumnName("rotor_speed_min")
|
|
|
|
|
.HasComment("Минимальные обороты на ВСП");
|
|
|
|
|
|
|
|
|
|
b.Property<double>("RotorTorqueMax")
|
|
|
|
|
.HasColumnType("double precision")
|
|
|
|
|
.HasColumnName("rotor_torque_max")
|
|
|
|
|
.HasComment("Максимальный момент на ВСП");
|
|
|
|
|
|
|
|
|
|
b.Property<double>("RotorTorqueMin")
|
|
|
|
|
.HasColumnType("double precision")
|
|
|
|
|
.HasColumnName("rotor_torque_min")
|
|
|
|
|
.HasComment("Минимальный момент на ВСП");
|
|
|
|
|
|
|
|
|
|
b.HasKey("Id");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("IdWell");
|
|
|
|
|
|
2021-10-14 17:02:20 +05:00
|
|
|
|
b.HasIndex("IdWellOperationCategory");
|
|
|
|
|
|
2021-10-14 14:46:20 +05:00
|
|
|
|
b.ToTable("t_drill_flow_chart");
|
2021-10-13 17:34:32 +05:00
|
|
|
|
|
|
|
|
|
b
|
|
|
|
|
.HasComment("Параметры корридоров бурения (диапазоны параметров бурения)");
|
|
|
|
|
});
|
|
|
|
|
|
2021-10-11 16:20:07 +05:00
|
|
|
|
modelBuilder.Entity("AsbCloudDb.Model.DrillParams", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Property<int>("Id")
|
|
|
|
|
.ValueGeneratedOnAdd()
|
|
|
|
|
.HasColumnType("integer")
|
|
|
|
|
.HasColumnName("id")
|
|
|
|
|
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
|
|
|
|
|
|
|
|
|
b.Property<double>("AxialLoadAvg")
|
|
|
|
|
.HasColumnType("double precision")
|
|
|
|
|
.HasColumnName("axial_load_avg")
|
|
|
|
|
.HasComment("Средняя нагрузка");
|
|
|
|
|
|
|
|
|
|
b.Property<double>("AxialLoadMax")
|
|
|
|
|
.HasColumnType("double precision")
|
|
|
|
|
.HasColumnName("axial_load_max")
|
|
|
|
|
.HasComment("Максимальная нагрузка");
|
|
|
|
|
|
|
|
|
|
b.Property<double>("AxialLoadMin")
|
|
|
|
|
.HasColumnType("double precision")
|
|
|
|
|
.HasColumnName("axial_load_min")
|
|
|
|
|
.HasComment("Минимальная нагрузка");
|
|
|
|
|
|
|
|
|
|
b.Property<double>("DepthEnd")
|
|
|
|
|
.HasColumnType("double precision")
|
|
|
|
|
.HasColumnName("depth_end")
|
|
|
|
|
.HasComment("Глубина окончания интервала");
|
|
|
|
|
|
|
|
|
|
b.Property<double>("DepthStart")
|
|
|
|
|
.HasColumnType("double precision")
|
|
|
|
|
.HasColumnName("depth_start")
|
|
|
|
|
.HasComment("Стартовая глубина");
|
|
|
|
|
|
|
|
|
|
b.Property<double>("FlowAvg")
|
|
|
|
|
.HasColumnType("double precision")
|
|
|
|
|
.HasColumnName("flow_avg")
|
|
|
|
|
.HasComment("Средний расход");
|
|
|
|
|
|
|
|
|
|
b.Property<double>("FlowMax")
|
|
|
|
|
.HasColumnType("double precision")
|
|
|
|
|
.HasColumnName("flow_max")
|
|
|
|
|
.HasComment("Максимальный расход");
|
|
|
|
|
|
|
|
|
|
b.Property<double>("FlowMin")
|
|
|
|
|
.HasColumnType("double precision")
|
|
|
|
|
.HasColumnName("flow_min")
|
|
|
|
|
.HasComment("Минимальный расход");
|
|
|
|
|
|
|
|
|
|
b.Property<int>("IdWell")
|
|
|
|
|
.HasColumnType("integer")
|
|
|
|
|
.HasColumnName("well_id")
|
|
|
|
|
.HasComment("Id скважины");
|
|
|
|
|
|
|
|
|
|
b.Property<int>("IdWellSectionType")
|
|
|
|
|
.HasColumnType("integer")
|
|
|
|
|
.HasColumnName("id_wellsection_type")
|
|
|
|
|
.HasComment("Id с типом секции скважины");
|
|
|
|
|
|
|
|
|
|
b.Property<double>("PressureAvg")
|
|
|
|
|
.HasColumnType("double precision")
|
|
|
|
|
.HasColumnName("pressure_avg")
|
|
|
|
|
.HasComment("Среднее давление");
|
|
|
|
|
|
|
|
|
|
b.Property<double>("PressureMax")
|
|
|
|
|
.HasColumnType("double precision")
|
|
|
|
|
.HasColumnName("pressure_max")
|
|
|
|
|
.HasComment("Максимальное давление");
|
|
|
|
|
|
|
|
|
|
b.Property<double>("PressureMin")
|
|
|
|
|
.HasColumnType("double precision")
|
|
|
|
|
.HasColumnName("pressure_min")
|
|
|
|
|
.HasComment("Минимальное давление");
|
|
|
|
|
|
2021-10-11 16:39:40 +05:00
|
|
|
|
b.Property<double>("RotorSpeedAvg")
|
2021-10-11 16:20:07 +05:00
|
|
|
|
.HasColumnType("double precision")
|
2021-10-11 16:39:40 +05:00
|
|
|
|
.HasColumnName("rotor_speed_avg")
|
2021-10-11 16:20:07 +05:00
|
|
|
|
.HasComment("Средние обороты на ВСП");
|
|
|
|
|
|
2021-10-11 16:39:40 +05:00
|
|
|
|
b.Property<double>("RotorSpeedMax")
|
2021-10-11 16:20:07 +05:00
|
|
|
|
.HasColumnType("double precision")
|
2021-10-11 16:39:40 +05:00
|
|
|
|
.HasColumnName("rotor_speed_max")
|
2021-10-11 16:20:07 +05:00
|
|
|
|
.HasComment("Максимальные обороты на ВСП");
|
|
|
|
|
|
2021-10-11 16:39:40 +05:00
|
|
|
|
b.Property<double>("RotorSpeedMin")
|
2021-10-11 16:20:07 +05:00
|
|
|
|
.HasColumnType("double precision")
|
2021-10-11 16:39:40 +05:00
|
|
|
|
.HasColumnName("rotor_speed_min")
|
2021-10-11 16:20:07 +05:00
|
|
|
|
.HasComment("Минимальные обороты на ВСП");
|
|
|
|
|
|
2021-10-11 16:39:40 +05:00
|
|
|
|
b.Property<double>("RotorTorqueAvg")
|
2021-10-11 16:20:07 +05:00
|
|
|
|
.HasColumnType("double precision")
|
2021-10-11 16:39:40 +05:00
|
|
|
|
.HasColumnName("rotor_torque_avg")
|
2021-10-11 16:20:07 +05:00
|
|
|
|
.HasComment("Средний момент на ВСП");
|
|
|
|
|
|
2021-10-11 16:39:40 +05:00
|
|
|
|
b.Property<double>("RotorTorqueMax")
|
2021-10-11 16:20:07 +05:00
|
|
|
|
.HasColumnType("double precision")
|
2021-10-11 16:39:40 +05:00
|
|
|
|
.HasColumnName("rotor_torque_max")
|
2021-10-11 16:20:07 +05:00
|
|
|
|
.HasComment("Максимальный момент на ВСП");
|
|
|
|
|
|
2021-10-11 16:39:40 +05:00
|
|
|
|
b.Property<double>("RotorTorqueMin")
|
2021-10-11 16:20:07 +05:00
|
|
|
|
.HasColumnType("double precision")
|
2021-10-11 16:39:40 +05:00
|
|
|
|
.HasColumnName("rotor_torque_min")
|
2021-10-11 16:20:07 +05:00
|
|
|
|
.HasComment("Минимальный момент на ВСП");
|
|
|
|
|
|
|
|
|
|
b.HasKey("Id");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("IdWell");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("IdWellSectionType");
|
|
|
|
|
|
|
|
|
|
b.ToTable("t_drill_params");
|
|
|
|
|
|
|
|
|
|
b
|
|
|
|
|
.HasComment("Режим бурения в секции (диапазоны параметров бурения)");
|
|
|
|
|
});
|
|
|
|
|
|
2021-09-07 14:04:30 +05:00
|
|
|
|
modelBuilder.Entity("AsbCloudDb.Model.FileCategory", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Property<int>("Id")
|
|
|
|
|
.ValueGeneratedOnAdd()
|
|
|
|
|
.HasColumnType("integer")
|
|
|
|
|
.HasColumnName("id")
|
2021-10-01 17:37:44 +05:00
|
|
|
|
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
2021-09-07 14:04:30 +05:00
|
|
|
|
|
|
|
|
|
b.Property<string>("Name")
|
|
|
|
|
.HasColumnType("text")
|
|
|
|
|
.HasColumnName("name")
|
|
|
|
|
.HasComment("Название категории");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("ShortName")
|
|
|
|
|
.HasColumnType("text")
|
|
|
|
|
.HasColumnName("short_name")
|
|
|
|
|
.HasComment("Короткое название категории");
|
|
|
|
|
|
|
|
|
|
b.HasKey("Id");
|
|
|
|
|
|
|
|
|
|
b.ToTable("t_file_category");
|
|
|
|
|
|
|
|
|
|
b
|
|
|
|
|
.HasComment("Категории файлов");
|
|
|
|
|
|
|
|
|
|
b.HasData(
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 1,
|
|
|
|
|
Name = "Растворный сервис",
|
|
|
|
|
ShortName = "fluidService"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 2,
|
|
|
|
|
Name = "Цементирование",
|
|
|
|
|
ShortName = "cement"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 3,
|
|
|
|
|
Name = "ННБ",
|
|
|
|
|
ShortName = "nnb"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 4,
|
|
|
|
|
Name = "ГТИ",
|
|
|
|
|
ShortName = "gti"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 5,
|
|
|
|
|
Name = "Документы по скважине",
|
|
|
|
|
ShortName = "wellDocuments"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 6,
|
|
|
|
|
Name = "Супервайзер",
|
|
|
|
|
ShortName = "supervisor"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 7,
|
|
|
|
|
Name = "Мастер",
|
|
|
|
|
ShortName = "master"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 8,
|
|
|
|
|
Name = "Последний замер бурового раствора ПЛАН",
|
|
|
|
|
ShortName = "fluidPlanLastData"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 9,
|
|
|
|
|
Name = "Последний замер бурового раствора ФАКТ",
|
|
|
|
|
ShortName = "fluidFactLastData"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 10,
|
|
|
|
|
Name = "Последние данные Шламограммы",
|
|
|
|
|
ShortName = "mudLastData"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 11,
|
|
|
|
|
Name = "Последние данные ННБ",
|
|
|
|
|
ShortName = "nnbLastData"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 12,
|
|
|
|
|
Name = "Рапорт",
|
|
|
|
|
ShortName = "report"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 13,
|
|
|
|
|
Name = "Программа бурения, части",
|
|
|
|
|
ShortName = "ПБч"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 14,
|
|
|
|
|
Name = "Программа бурения",
|
|
|
|
|
ShortName = "ПБ"
|
|
|
|
|
});
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("AsbCloudDb.Model.FileInfo", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Property<int>("Id")
|
|
|
|
|
.ValueGeneratedOnAdd()
|
|
|
|
|
.HasColumnType("integer")
|
|
|
|
|
.HasColumnName("id")
|
2021-10-01 17:37:44 +05:00
|
|
|
|
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
2021-09-07 14:04:30 +05:00
|
|
|
|
|
|
|
|
|
b.Property<int?>("IdAuthor")
|
|
|
|
|
.HasColumnType("integer")
|
|
|
|
|
.HasColumnName("id_author")
|
|
|
|
|
.HasComment("Id пользователя, загрузившего файл");
|
|
|
|
|
|
|
|
|
|
b.Property<int>("IdCategory")
|
|
|
|
|
.HasColumnType("integer")
|
|
|
|
|
.HasColumnName("id_category")
|
|
|
|
|
.HasComment("id категории файла");
|
|
|
|
|
|
|
|
|
|
b.Property<int>("IdWell")
|
|
|
|
|
.HasColumnType("integer")
|
|
|
|
|
.HasColumnName("id_well")
|
|
|
|
|
.HasComment("id скважины");
|
|
|
|
|
|
|
|
|
|
b.Property<bool>("IsDeleted")
|
|
|
|
|
.HasColumnType("boolean")
|
|
|
|
|
.HasColumnName("is_deleted")
|
|
|
|
|
.HasComment("Удален ли файл");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("Name")
|
|
|
|
|
.HasColumnType("text")
|
|
|
|
|
.HasColumnName("name")
|
|
|
|
|
.HasComment("Название файла");
|
|
|
|
|
|
2021-10-29 12:47:18 +05:00
|
|
|
|
b.Property<FilePublishInfo>("PublishInfo")
|
|
|
|
|
.HasColumnType("jsonb")
|
|
|
|
|
.HasColumnName("publish_info")
|
|
|
|
|
.HasComment("Информация о файле в облаке");
|
|
|
|
|
|
2021-09-07 14:04:30 +05:00
|
|
|
|
b.Property<long>("Size")
|
|
|
|
|
.HasColumnType("bigint")
|
|
|
|
|
.HasColumnName("file_size")
|
|
|
|
|
.HasComment("Размер файла");
|
|
|
|
|
|
|
|
|
|
b.Property<DateTime>("UploadDate")
|
|
|
|
|
.HasColumnType("timestamp with time zone")
|
|
|
|
|
.HasColumnName("date");
|
|
|
|
|
|
|
|
|
|
b.HasKey("Id");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("IdAuthor");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("IdCategory");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("IdWell");
|
|
|
|
|
|
|
|
|
|
b.ToTable("t_file_info");
|
|
|
|
|
|
|
|
|
|
b
|
|
|
|
|
.HasComment("Файлы всех категорий");
|
|
|
|
|
});
|
|
|
|
|
|
2021-11-01 16:41:25 +05:00
|
|
|
|
modelBuilder.Entity("AsbCloudDb.Model.FileMark", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Property<int>("Id")
|
|
|
|
|
.ValueGeneratedOnAdd()
|
|
|
|
|
.HasColumnType("integer")
|
|
|
|
|
.HasColumnName("id")
|
|
|
|
|
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
|
|
|
|
|
|
|
|
|
b.Property<string>("Comment")
|
|
|
|
|
.HasMaxLength(255)
|
|
|
|
|
.HasColumnType("character varying(255)")
|
|
|
|
|
.HasColumnName("comment")
|
|
|
|
|
.HasComment("Комментарий");
|
|
|
|
|
|
|
|
|
|
b.Property<DateTime>("DateCreated")
|
|
|
|
|
.HasColumnType("timestamp without time zone")
|
|
|
|
|
.HasColumnName("date_created")
|
|
|
|
|
.HasComment("Дата совершенного действия");
|
|
|
|
|
|
|
|
|
|
b.Property<int>("IdFile")
|
|
|
|
|
.HasColumnType("integer")
|
|
|
|
|
.HasColumnName("id_file")
|
|
|
|
|
.HasComment("id файла");
|
|
|
|
|
|
2021-11-03 14:12:39 +05:00
|
|
|
|
b.Property<int>("IdMarkType")
|
2021-11-01 16:41:25 +05:00
|
|
|
|
.HasColumnType("integer")
|
2021-11-03 14:12:39 +05:00
|
|
|
|
.HasColumnName("id_mark_type")
|
|
|
|
|
.HasComment("0 - Согласован");
|
2021-11-01 16:41:25 +05:00
|
|
|
|
|
|
|
|
|
b.Property<int>("IdUser")
|
|
|
|
|
.HasColumnType("integer")
|
|
|
|
|
.HasColumnName("id_user")
|
|
|
|
|
.HasComment("id пользователя");
|
|
|
|
|
|
|
|
|
|
b.Property<bool>("IsDeleted")
|
|
|
|
|
.HasColumnType("boolean")
|
|
|
|
|
.HasColumnName("is_deleted")
|
|
|
|
|
.HasComment("Помечен ли файл как удаленный");
|
|
|
|
|
|
|
|
|
|
b.HasKey("Id");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("IdFile");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("IdUser");
|
|
|
|
|
|
|
|
|
|
b.ToTable("t_file_mark");
|
|
|
|
|
|
|
|
|
|
b
|
|
|
|
|
.HasComment("Действия с файлами.");
|
|
|
|
|
});
|
|
|
|
|
|
2021-09-07 14:04:30 +05:00
|
|
|
|
modelBuilder.Entity("AsbCloudDb.Model.Measure", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Property<int>("Id")
|
|
|
|
|
.ValueGeneratedOnAdd()
|
|
|
|
|
.HasColumnType("integer")
|
|
|
|
|
.HasColumnName("id")
|
2021-10-01 17:37:44 +05:00
|
|
|
|
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
2021-09-07 14:04:30 +05:00
|
|
|
|
|
|
|
|
|
b.Property<Dictionary<string, object>>("Data")
|
|
|
|
|
.HasColumnType("jsonb")
|
|
|
|
|
.HasColumnName("data")
|
|
|
|
|
.HasComment("Данные таблицы последних данных");
|
|
|
|
|
|
|
|
|
|
b.Property<int>("IdCategory")
|
|
|
|
|
.HasColumnType("integer")
|
|
|
|
|
.HasColumnName("id_category")
|
|
|
|
|
.HasComment("id категории");
|
|
|
|
|
|
|
|
|
|
b.Property<int>("IdWell")
|
|
|
|
|
.HasColumnType("integer")
|
|
|
|
|
.HasColumnName("id_well")
|
|
|
|
|
.HasComment("id скважины");
|
|
|
|
|
|
|
|
|
|
b.Property<bool>("IsDeleted")
|
|
|
|
|
.HasColumnType("boolean")
|
|
|
|
|
.HasColumnName("is_deleted")
|
|
|
|
|
.HasComment("Пометка удаленным");
|
|
|
|
|
|
|
|
|
|
b.Property<DateTime>("Timestamp")
|
|
|
|
|
.HasColumnType("timestamp without time zone")
|
|
|
|
|
.HasColumnName("timestamp")
|
|
|
|
|
.HasComment("время добавления");
|
|
|
|
|
|
|
|
|
|
b.HasKey("Id");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("IdCategory");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("IdWell");
|
|
|
|
|
|
|
|
|
|
b.ToTable("t_measure");
|
|
|
|
|
|
|
|
|
|
b
|
|
|
|
|
.HasComment("Таблица c данными для вкладки 'Последние данные'");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("AsbCloudDb.Model.MeasureCategory", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Property<int>("Id")
|
|
|
|
|
.ValueGeneratedOnAdd()
|
|
|
|
|
.HasColumnType("integer")
|
|
|
|
|
.HasColumnName("id")
|
2021-10-01 17:37:44 +05:00
|
|
|
|
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
2021-09-07 14:04:30 +05:00
|
|
|
|
|
|
|
|
|
b.Property<string>("Name")
|
|
|
|
|
.HasColumnType("text")
|
|
|
|
|
.HasColumnName("name")
|
|
|
|
|
.HasComment("Название категории");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("ShortName")
|
|
|
|
|
.HasColumnType("text")
|
|
|
|
|
.HasColumnName("short_name")
|
|
|
|
|
.HasComment("Короткое название категории");
|
|
|
|
|
|
|
|
|
|
b.HasKey("Id");
|
|
|
|
|
|
|
|
|
|
b.ToTable("t_measure_category");
|
|
|
|
|
|
|
|
|
|
b
|
|
|
|
|
.HasComment("Категория последних данных");
|
|
|
|
|
|
|
|
|
|
b.HasData(
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 1,
|
|
|
|
|
Name = "Показатели бурового раствора",
|
|
|
|
|
ShortName = "Раствор"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 2,
|
|
|
|
|
Name = "Шламограмма",
|
|
|
|
|
ShortName = "Шламограмма"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 3,
|
|
|
|
|
Name = "ННБ",
|
|
|
|
|
ShortName = "ННБ"
|
|
|
|
|
});
|
|
|
|
|
});
|
|
|
|
|
|
2021-11-24 11:30:29 +05:00
|
|
|
|
modelBuilder.Entity("AsbCloudDb.Model.Permission", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Property<int>("Id")
|
|
|
|
|
.ValueGeneratedOnAdd()
|
|
|
|
|
.HasColumnType("integer")
|
|
|
|
|
.HasColumnName("id")
|
|
|
|
|
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
|
|
|
|
|
2021-11-29 12:39:28 +05:00
|
|
|
|
b.Property<string>("Caption")
|
2021-11-24 11:30:29 +05:00
|
|
|
|
.HasMaxLength(255)
|
|
|
|
|
.HasColumnType("character varying(255)")
|
2021-11-29 12:39:28 +05:00
|
|
|
|
.HasColumnName("caption")
|
|
|
|
|
.HasComment("Название");
|
2021-11-24 11:30:29 +05:00
|
|
|
|
|
2021-11-29 12:39:28 +05:00
|
|
|
|
b.Property<int>("Type")
|
|
|
|
|
.HasColumnType("integer")
|
|
|
|
|
.HasColumnName("type")
|
|
|
|
|
.HasComment("1-чтение, 2-запись, 3-чтение и запись");
|
2021-11-24 11:30:29 +05:00
|
|
|
|
|
|
|
|
|
b.HasKey("Id");
|
|
|
|
|
|
|
|
|
|
b.ToTable("t_permission");
|
|
|
|
|
|
|
|
|
|
b
|
2021-11-29 12:39:28 +05:00
|
|
|
|
.HasComment("Разрешения на доступ к данным");
|
2021-11-24 11:30:29 +05:00
|
|
|
|
});
|
|
|
|
|
|
2021-09-07 14:04:30 +05:00
|
|
|
|
modelBuilder.Entity("AsbCloudDb.Model.RelationCompanyWell", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Property<int>("IdCompany")
|
|
|
|
|
.HasColumnType("integer")
|
|
|
|
|
.HasColumnName("id_company");
|
|
|
|
|
|
2021-09-14 17:17:33 +05:00
|
|
|
|
b.Property<int>("IdWell")
|
|
|
|
|
.HasColumnType("integer")
|
|
|
|
|
.HasColumnName("id_well");
|
|
|
|
|
|
|
|
|
|
b.HasKey("IdCompany", "IdWell");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("IdWell");
|
|
|
|
|
|
|
|
|
|
b.ToTable("t_relation_company_well");
|
|
|
|
|
|
|
|
|
|
b
|
|
|
|
|
.HasComment("отношение скважин и компаний");
|
|
|
|
|
});
|
|
|
|
|
|
2021-11-29 12:39:28 +05:00
|
|
|
|
modelBuilder.Entity("AsbCloudDb.Model.RelationUserRolePermission", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Property<int>("Id")
|
|
|
|
|
.ValueGeneratedOnAdd()
|
|
|
|
|
.HasColumnType("integer")
|
|
|
|
|
.HasColumnName("id")
|
|
|
|
|
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
|
|
|
|
|
|
|
|
|
b.Property<int>("IdPermission")
|
|
|
|
|
.HasColumnType("integer")
|
|
|
|
|
.HasColumnName("id_permission");
|
|
|
|
|
|
|
|
|
|
b.Property<int>("IdUserRole")
|
|
|
|
|
.HasColumnType("integer")
|
|
|
|
|
.HasColumnName("id_user_role");
|
|
|
|
|
|
|
|
|
|
b.HasKey("Id");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("IdPermission");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("IdUserRole");
|
|
|
|
|
|
|
|
|
|
b.ToTable("t_relation_user_role_permission");
|
|
|
|
|
|
|
|
|
|
b
|
|
|
|
|
.HasComment("Отношение ролей пользователей и разрешений доступа");
|
|
|
|
|
});
|
|
|
|
|
|
2021-11-24 11:30:29 +05:00
|
|
|
|
modelBuilder.Entity("AsbCloudDb.Model.RelationUserUserRole", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Property<int>("Id")
|
|
|
|
|
.ValueGeneratedOnAdd()
|
|
|
|
|
.HasColumnType("integer")
|
|
|
|
|
.HasColumnName("id")
|
|
|
|
|
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
|
|
|
|
|
|
|
|
|
b.Property<int>("IdUser")
|
|
|
|
|
.HasColumnType("integer")
|
|
|
|
|
.HasColumnName("id_user");
|
|
|
|
|
|
|
|
|
|
b.Property<int>("IdUserRole")
|
|
|
|
|
.HasColumnType("integer")
|
|
|
|
|
.HasColumnName("id_user_role");
|
|
|
|
|
|
|
|
|
|
b.HasKey("Id");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("IdUser");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("IdUserRole");
|
|
|
|
|
|
|
|
|
|
b.ToTable("t_relation_user_user_role");
|
|
|
|
|
|
|
|
|
|
b
|
|
|
|
|
.HasComment("Отношение пользователей и ролей");
|
|
|
|
|
});
|
|
|
|
|
|
2021-09-14 17:17:33 +05:00
|
|
|
|
modelBuilder.Entity("AsbCloudDb.Model.ReportProperty", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Property<int>("Id")
|
|
|
|
|
.ValueGeneratedOnAdd()
|
|
|
|
|
.HasColumnType("integer")
|
|
|
|
|
.HasColumnName("id")
|
2021-10-01 17:37:44 +05:00
|
|
|
|
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
2021-09-14 17:17:33 +05:00
|
|
|
|
|
|
|
|
|
b.Property<DateTimeOffset>("Begin")
|
|
|
|
|
.HasColumnType("timestamp with time zone")
|
|
|
|
|
.HasColumnName("begin");
|
|
|
|
|
|
|
|
|
|
b.Property<DateTimeOffset>("End")
|
|
|
|
|
.HasColumnType("timestamp with time zone")
|
|
|
|
|
.HasColumnName("end")
|
|
|
|
|
.HasComment("timestamp with time zone");
|
|
|
|
|
|
|
|
|
|
b.Property<int>("Format")
|
|
|
|
|
.HasColumnType("integer")
|
|
|
|
|
.HasColumnName("format")
|
|
|
|
|
.HasComment("Формат отчета");
|
|
|
|
|
|
|
|
|
|
b.Property<int>("IdFile")
|
|
|
|
|
.HasColumnType("integer")
|
|
|
|
|
.HasColumnName("id_file")
|
|
|
|
|
.HasComment("id файла-родителя");
|
|
|
|
|
|
|
|
|
|
b.Property<int>("IdWell")
|
|
|
|
|
.HasColumnType("integer")
|
|
|
|
|
.HasColumnName("id_well")
|
|
|
|
|
.HasComment("id скважины");
|
|
|
|
|
|
|
|
|
|
b.Property<int>("Step")
|
|
|
|
|
.HasColumnType("integer")
|
|
|
|
|
.HasColumnName("step")
|
|
|
|
|
.HasComment("размер шага в секундах");
|
|
|
|
|
|
|
|
|
|
b.HasKey("Id");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("IdFile");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("IdWell");
|
|
|
|
|
|
|
|
|
|
b.ToTable("t_report_property");
|
|
|
|
|
|
|
|
|
|
b
|
|
|
|
|
.HasComment("Отчеты с данными по буровым");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("AsbCloudDb.Model.Telemetry", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Property<int>("Id")
|
|
|
|
|
.ValueGeneratedOnAdd()
|
|
|
|
|
.HasColumnType("integer")
|
|
|
|
|
.HasColumnName("id")
|
2021-10-01 17:37:44 +05:00
|
|
|
|
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
2021-09-14 17:17:33 +05:00
|
|
|
|
|
|
|
|
|
b.Property<TelemetryInfo>("Info")
|
|
|
|
|
.HasColumnType("jsonb")
|
|
|
|
|
.HasColumnName("info")
|
|
|
|
|
.HasComment("Информация с панели о скважине");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("RemoteUid")
|
|
|
|
|
.HasColumnType("text")
|
|
|
|
|
.HasColumnName("remote_uid")
|
|
|
|
|
.HasComment("Идентификатор передающего устройства. Может повторяться в списке, так как комплекты оборудования переезжают от скв. к скв.");
|
|
|
|
|
|
2021-11-16 13:14:31 +05:00
|
|
|
|
b.Property<TelemetryTimeZone>("TelemetryTimeZone")
|
|
|
|
|
.HasColumnType("jsonb")
|
|
|
|
|
.HasColumnName("timezone")
|
|
|
|
|
.HasComment("Смещение часового пояса от UTC");
|
|
|
|
|
|
2021-09-14 17:17:33 +05:00
|
|
|
|
b.HasKey("Id");
|
|
|
|
|
|
|
|
|
|
b.HasIndex(new[] { "RemoteUid" }, "t_telemetry_remote_uid_index");
|
|
|
|
|
|
|
|
|
|
b.ToTable("t_telemetry");
|
|
|
|
|
|
|
|
|
|
b
|
|
|
|
|
.HasComment("таблица привязки телеметрии от комплектов к конкретной скважине.");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("AsbCloudDb.Model.TelemetryAnalysis", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Property<int>("Id")
|
|
|
|
|
.ValueGeneratedOnAdd()
|
|
|
|
|
.HasColumnType("integer")
|
|
|
|
|
.HasColumnName("id")
|
2021-10-01 17:37:44 +05:00
|
|
|
|
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
2021-09-14 17:17:33 +05:00
|
|
|
|
|
|
|
|
|
b.Property<int>("DurationSec")
|
|
|
|
|
.HasColumnType("integer")
|
|
|
|
|
.HasColumnName("duration_sec")
|
|
|
|
|
.HasComment("Кол-во секунд после предыдущей операции");
|
|
|
|
|
|
|
|
|
|
b.Property<int>("IdOperation")
|
|
|
|
|
.HasColumnType("integer")
|
|
|
|
|
.HasColumnName("id_operation");
|
|
|
|
|
|
|
|
|
|
b.Property<int>("IdTelemetry")
|
|
|
|
|
.HasColumnType("integer")
|
|
|
|
|
.HasColumnName("id_telemetry");
|
|
|
|
|
|
|
|
|
|
b.Property<bool>("IsBitPositionDecreasing")
|
|
|
|
|
.HasColumnType("boolean")
|
|
|
|
|
.HasColumnName("is_bit_position_decreasing")
|
|
|
|
|
.HasComment("Долото поднимается");
|
|
|
|
|
|
|
|
|
|
b.Property<bool>("IsBitPositionIncreasing")
|
|
|
|
|
.HasColumnType("boolean")
|
|
|
|
|
.HasColumnName("is_bit_position_increasing")
|
|
|
|
|
.HasComment("Долото спускается");
|
|
|
|
|
|
|
|
|
|
b.Property<bool>("IsBitPositionLt20")
|
|
|
|
|
.HasColumnType("boolean")
|
|
|
|
|
.HasColumnName("is_bit_posision_lt_20")
|
|
|
|
|
.HasComment("Положение долота меньше 20м");
|
|
|
|
|
|
|
|
|
|
b.Property<bool>("IsBlockPositionDecreasing")
|
|
|
|
|
.HasColumnType("boolean")
|
|
|
|
|
.HasColumnName("is_block_posision_decresing")
|
|
|
|
|
.HasComment("Талевый блок поднимается");
|
|
|
|
|
|
|
|
|
|
b.Property<bool>("IsBlockPositionIncreasing")
|
|
|
|
|
.HasColumnType("boolean")
|
|
|
|
|
.HasColumnName("is_block_posision_incresing")
|
|
|
|
|
.HasComment("Талевый блок спускается");
|
|
|
|
|
|
|
|
|
|
b.Property<bool>("IsHookWeightLt3")
|
|
|
|
|
.HasColumnType("boolean")
|
|
|
|
|
.HasColumnName("is_hook_weight_lt_3")
|
|
|
|
|
.HasComment("Вес на крюке менее 3т");
|
|
|
|
|
|
|
|
|
|
b.Property<bool>("IsHookWeightNotChanges")
|
|
|
|
|
.HasColumnType("boolean")
|
|
|
|
|
.HasColumnName("is_hook_weight_not_changes")
|
|
|
|
|
.HasComment("Вес на крюке не меняется");
|
|
|
|
|
|
|
|
|
|
b.Property<bool>("IsPressureGt20")
|
|
|
|
|
.HasColumnType("boolean")
|
|
|
|
|
.HasColumnName("is_pressure_gt_20")
|
|
|
|
|
.HasComment("Давоение более 20");
|
|
|
|
|
|
|
|
|
|
b.Property<bool>("IsPressureLt20")
|
|
|
|
|
.HasColumnType("boolean")
|
|
|
|
|
.HasColumnName("is_pressure_lt_20")
|
|
|
|
|
.HasComment("Давление менее 20");
|
|
|
|
|
|
2021-10-01 17:37:44 +05:00
|
|
|
|
b.Property<bool>("IsRotorSpeedGt5")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnType("boolean")
|
|
|
|
|
.HasColumnName("is_rotor_speed_gt_3")
|
|
|
|
|
.HasComment("Обороты ротора выше 3");
|
|
|
|
|
|
2021-10-01 17:37:44 +05:00
|
|
|
|
b.Property<bool>("IsRotorSpeedLt5")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnType("boolean")
|
|
|
|
|
.HasColumnName("is_rotor_speed_lt_3")
|
|
|
|
|
.HasComment("Обороты ротора ниже 3");
|
|
|
|
|
|
|
|
|
|
b.Property<bool>("IsWellDepthDecreasing")
|
|
|
|
|
.HasColumnType("boolean")
|
|
|
|
|
.HasColumnName("is_well_depth_decreasing")
|
|
|
|
|
.HasComment("Глубина забоя не увеличивается");
|
|
|
|
|
|
|
|
|
|
b.Property<bool>("IsWellDepthIncreasing")
|
|
|
|
|
.HasColumnType("boolean")
|
|
|
|
|
.HasColumnName("is_well_depth_increasing")
|
|
|
|
|
.HasComment("Глубина забоя увеличивается");
|
|
|
|
|
|
|
|
|
|
b.Property<double?>("OperationEndDepth")
|
|
|
|
|
.HasColumnType("double precision")
|
|
|
|
|
.HasColumnName("operation_end_depth")
|
|
|
|
|
.HasComment("Глубина, на которой закончилась операция");
|
|
|
|
|
|
|
|
|
|
b.Property<double?>("OperationStartDepth")
|
|
|
|
|
.HasColumnType("double precision")
|
|
|
|
|
.HasColumnName("operation_start_depth")
|
|
|
|
|
.HasComment("Глубина, на которой началась операция");
|
|
|
|
|
|
|
|
|
|
b.Property<long>("UnixDate")
|
|
|
|
|
.HasColumnType("bigint")
|
|
|
|
|
.HasColumnName("unix_date")
|
|
|
|
|
.HasComment("Unix timestamp для Linq запросов с вычислением дат");
|
|
|
|
|
|
|
|
|
|
b.HasKey("Id");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("IdOperation");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("IdTelemetry");
|
|
|
|
|
|
|
|
|
|
b.ToTable("t_telemetry_analysis");
|
|
|
|
|
|
|
|
|
|
b
|
|
|
|
|
.HasComment("События на скважине");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("AsbCloudDb.Model.TelemetryDataSaub", b =>
|
|
|
|
|
{
|
2021-11-13 18:47:11 +05:00
|
|
|
|
b.Property<int>("IdTelemetry")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnType("integer")
|
2021-11-13 18:47:11 +05:00
|
|
|
|
.HasColumnName("id_telemetry");
|
|
|
|
|
|
|
|
|
|
b.Property<DateTime>("Date")
|
|
|
|
|
.HasColumnType("timestamp with time zone")
|
|
|
|
|
.HasColumnName("date")
|
|
|
|
|
.HasComment("'2021-10-19 18:23:54+05'");
|
2021-09-14 17:17:33 +05:00
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("AxialLoad")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("axial_load")
|
|
|
|
|
.HasComment("Осевая нагрузка");
|
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("AxialLoadLimitMax")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("axial_load_limit_max")
|
|
|
|
|
.HasComment("Осевая нагрузка. Аварийная макс.");
|
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("AxialLoadSp")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("axial_load_sp")
|
|
|
|
|
.HasComment("Осевая нагрузка. Задание");
|
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("BitDepth")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("bit_depth")
|
|
|
|
|
.HasComment("Положение инструмента");
|
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("BlockPosition")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("block_position")
|
|
|
|
|
.HasComment("Высота талевого блока");
|
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("BlockPositionMax")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("block_position_max")
|
|
|
|
|
.HasComment("Талевый блок. Макс положение");
|
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("BlockPositionMin")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("block_position_min")
|
|
|
|
|
.HasComment("Талевый блок. Мин положение");
|
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("BlockSpeed")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("block_speed")
|
|
|
|
|
.HasComment("Скорость талевого блока");
|
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("BlockSpeedSp")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("block_speed_sp")
|
|
|
|
|
.HasComment("Скорости талевого блока. Задание");
|
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("BlockSpeedSpDevelop")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("block_speed_sp_develop")
|
|
|
|
|
.HasComment("Талевый блок. Задание скорости для проработки");
|
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("BlockSpeedSpRotor")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("block_speed_sp_rotor")
|
|
|
|
|
.HasComment("Талевый блок. Задание скорости для роторного бурения");
|
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("BlockSpeedSpSlide")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("block_speed_sp_slide")
|
|
|
|
|
.HasComment("Талевый блок. Задание скорости для режима слайда");
|
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("Flow")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("flow")
|
|
|
|
|
.HasComment("Расход");
|
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("FlowDeltaLimitMax")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("flow_delta_limit_max")
|
|
|
|
|
.HasComment("Расход. Аварийный макс.");
|
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("FlowIdle")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("flow_idle")
|
|
|
|
|
.HasComment("Расход. Холостой ход");
|
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("HookWeight")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("hook_weight")
|
|
|
|
|
.HasComment("Вес на крюке");
|
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("HookWeightIdle")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("hook_weight_idle")
|
|
|
|
|
.HasComment("Вес на крюке. Холостой ход");
|
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("HookWeightLimitMax")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("hook_weight_limit_max")
|
|
|
|
|
.HasComment("Вес на крюке. Затяжка");
|
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("HookWeightLimitMin")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("hook_weight_limit_min")
|
|
|
|
|
.HasComment("Вес на крюке. Посадка");
|
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<short?>("IdFeedRegulator")
|
|
|
|
|
.HasColumnType("smallint")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("id_feed_regulator")
|
|
|
|
|
.HasComment("Текущий критерий бурения");
|
|
|
|
|
|
|
|
|
|
b.Property<int?>("IdUser")
|
|
|
|
|
.HasColumnType("integer")
|
|
|
|
|
.HasColumnName("id_user")
|
|
|
|
|
.HasComment("Пользователь САУБ");
|
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<short?>("Mode")
|
|
|
|
|
.HasColumnType("smallint")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("mode")
|
|
|
|
|
.HasComment("Режим САУБ");
|
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<short?>("MseState")
|
|
|
|
|
.HasColumnType("smallint")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("mse_state")
|
|
|
|
|
.HasComment("Текущее состояние работы MSE");
|
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("Pressure")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("pressure")
|
|
|
|
|
.HasComment("Давление");
|
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("PressureDeltaLimitMax")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("pressure_delta_limit_max")
|
|
|
|
|
.HasComment("Давление дифф. Аварийное макс.");
|
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("PressureIdle")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("pressure_idle")
|
|
|
|
|
.HasComment("Давление. Холостой ход");
|
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("PressureSp")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("pressure_sp")
|
|
|
|
|
.HasComment("Давление. Задание");
|
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("PressureSpDevelop")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("pressure_sp_develop")
|
|
|
|
|
.HasComment("Давление. Задание для проработки");
|
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("PressureSpRotor")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("pressure_sp_rotor")
|
|
|
|
|
.HasComment("Давление. Задание для роторного бурения");
|
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("PressureSpSlide")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("pressure_sp_slide")
|
|
|
|
|
.HasComment("Давление. Задание для режима слайда");
|
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("RotorSpeed")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("rotor_speed")
|
|
|
|
|
.HasComment("Обороты ротора");
|
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("RotorTorque")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("rotor_torque")
|
|
|
|
|
.HasComment("Момент на роторе");
|
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("RotorTorqueIdle")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("rotor_torque_idle")
|
|
|
|
|
.HasComment("Момент на роторе. Холостой ход");
|
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("RotorTorqueLimitMax")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("rotor_torque_limit_max")
|
|
|
|
|
.HasComment("Момент на роторе. Аварийный макс.");
|
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("RotorTorqueSp")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("rotor_torque_sp")
|
|
|
|
|
.HasComment("Момент на роторе. Задание");
|
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("WellDepth")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("well_depth")
|
|
|
|
|
.HasComment("Глубина забоя");
|
2021-09-07 14:04:30 +05:00
|
|
|
|
|
2021-11-13 18:47:11 +05:00
|
|
|
|
b.HasKey("IdTelemetry", "Date");
|
2021-09-07 14:04:30 +05:00
|
|
|
|
|
2021-09-14 17:17:33 +05:00
|
|
|
|
b.ToTable("t_telemetry_data_saub");
|
2021-09-07 14:04:30 +05:00
|
|
|
|
|
|
|
|
|
b
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasComment("набор основных данных по SAUB");
|
2021-09-07 14:04:30 +05:00
|
|
|
|
});
|
|
|
|
|
|
2021-09-14 17:17:33 +05:00
|
|
|
|
modelBuilder.Entity("AsbCloudDb.Model.TelemetryDataSpin", b =>
|
2021-09-07 14:04:30 +05:00
|
|
|
|
{
|
2021-11-13 18:47:11 +05:00
|
|
|
|
b.Property<int>("IdTelemetry")
|
2021-09-07 14:04:30 +05:00
|
|
|
|
.HasColumnType("integer")
|
2021-11-13 18:47:11 +05:00
|
|
|
|
.HasColumnName("id_telemetry");
|
|
|
|
|
|
|
|
|
|
b.Property<DateTime>("Date")
|
|
|
|
|
.HasColumnType("timestamp with time zone")
|
|
|
|
|
.HasColumnName("date")
|
|
|
|
|
.HasComment("'2021-10-19 18:23:54+05'");
|
2021-09-07 14:04:30 +05:00
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("BreakAngleK")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("break_angle_k")
|
|
|
|
|
.HasComment("Коэффициент для расчёта за какой угол нужно тормозить");
|
2021-09-07 14:04:30 +05:00
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("BreakAngleLeft")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("break_angle_left")
|
|
|
|
|
.HasComment("Угол торможения влево при работе по моменту");
|
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("EncoderResolution")
|
|
|
|
|
.HasColumnType("real")
|
2021-11-15 14:54:10 +05:00
|
|
|
|
.HasColumnName("encoder_resolution")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasComment(" Разрешение энкодера");
|
2021-09-07 14:04:30 +05:00
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<short?>("Mode")
|
|
|
|
|
.HasColumnType("smallint")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("mode")
|
|
|
|
|
.HasComment("Выбранный режим управления");
|
2021-09-07 14:04:30 +05:00
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("PidMuxTorqueLeftLimit")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("pid_mux_torque_left_limit")
|
|
|
|
|
.HasComment(" Момент при котором определяется ехать назад по моменту или по скорости");
|
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("PositionRight")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("position_right")
|
|
|
|
|
.HasComment("Крайний правый угол осциляции");
|
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("PositionZero")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("position_zero")
|
|
|
|
|
.HasComment("Нулевая позиция осциляции");
|
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("Ratio")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("ratio")
|
|
|
|
|
.HasComment(" Коэффициент редукции редектора");
|
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("ReverseKTorque")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("reverse_k_torque")
|
|
|
|
|
.HasComment("Коэффициент на который умножается момент, для того чтобы система поняла что мы движемся в обратную сторону");
|
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<short?>("ReverseSpeedSpZeroTime")
|
|
|
|
|
.HasColumnType("smallint")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("reverse_speed_sp_zero_time")
|
|
|
|
|
.HasComment("Время выдачи сигнала нулевой скорости на при смене направления");
|
2021-09-07 14:04:30 +05:00
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("RevolsLeftLimit")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("revols_left_limit")
|
|
|
|
|
.HasComment("Ограничение числа оборотов влево");
|
2021-09-07 14:04:30 +05:00
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("RevolsLeftTotal")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("revols_left_total")
|
|
|
|
|
.HasComment("Суммарное количество оборотов влево");
|
2021-09-07 14:04:30 +05:00
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("RevolsRightLimit")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("revols_right_limit")
|
|
|
|
|
.HasComment("Ограничение числа оборотов вправо");
|
2021-09-07 14:04:30 +05:00
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("RevolsRightTotal")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("revols_right_total")
|
|
|
|
|
.HasComment("Суммарное количество оборотов вправо");
|
2021-09-07 14:04:30 +05:00
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("RotorTorqueAvg")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("rotor_torque_avg")
|
|
|
|
|
.HasComment(" Момент в роторе средний");
|
2021-09-07 14:04:30 +05:00
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("SpeedLeftSp")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("speed_left_sp")
|
|
|
|
|
.HasComment("Заданная скорость вращения влево");
|
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("SpeedRightSp")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("speed_right_sp")
|
|
|
|
|
.HasComment("Заданная скорость вращения вправо");
|
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<short?>("State")
|
|
|
|
|
.HasColumnType("smallint")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("state")
|
|
|
|
|
.HasComment("Переменная этапа");
|
2021-09-07 14:04:30 +05:00
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("TopDriveSpeed")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("top_drive_speed")
|
|
|
|
|
.HasComment("Скорость СВП");
|
2021-09-07 14:04:30 +05:00
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<short?>("TopDriveSpeedErr")
|
|
|
|
|
.HasColumnType("smallint")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("top_drive_speed_err");
|
2021-09-07 14:04:30 +05:00
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("TopDriveSpeedMax")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("top_drive_speed_max")
|
|
|
|
|
.HasComment("верхний предел");
|
2021-09-07 14:04:30 +05:00
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("TopDriveSpeedMin")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("top_drive_speed_min")
|
|
|
|
|
.HasComment("нижний предел");
|
2021-09-07 14:04:30 +05:00
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("TopDriveSpeedOffset")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("top_drive_speed_offset")
|
|
|
|
|
.HasComment("смещение");
|
2021-09-07 14:04:30 +05:00
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("TopDriveSpeedSpFrom")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("top_drive_speed_sp_from")
|
|
|
|
|
.HasComment("Заданная скорость c СВП");
|
2021-09-07 14:04:30 +05:00
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<short?>("TopDriveSpeedSpFromErr")
|
|
|
|
|
.HasColumnType("smallint")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("top_drive_speed_sp_from_err");
|
2021-09-07 14:04:30 +05:00
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("TopDriveSpeedSpFromMax")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("top_drive_speed_sp_from_max");
|
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("TopDriveSpeedSpFromMin")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("top_drive_speed_sp_from_min");
|
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("TopDriveSpeedSpFromOffset")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("top_drive_speed_sp_from_offset");
|
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("TopDriveSpeedSpTo")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("top_drive_speed_sp_to")
|
|
|
|
|
.HasComment("Задание скорости на СВП");
|
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<short?>("TopDriveSpeedSpToErr")
|
|
|
|
|
.HasColumnType("smallint")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("top_drive_speed_sp_to_err");
|
2021-09-07 14:04:30 +05:00
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("TopDriveSpeedSpToMax")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("top_drive_speed_sp_to_max");
|
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("TopDriveSpeedSpToMin")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("top_drive_speed_sp_to_min");
|
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("TopDriveSpeedSpToOffset")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("top_drive_speed_sp_to_offset");
|
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("TopDriveTorque")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("top_drive_torque")
|
|
|
|
|
.HasComment("Момент СВП");
|
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<short?>("TopDriveTorqueErr")
|
|
|
|
|
.HasColumnType("smallint")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("top_drive_torque_err");
|
2021-09-07 14:04:30 +05:00
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("TopDriveTorqueMax")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("top_drive_torque_max");
|
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("TopDriveTorqueMin")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("top_drive_torque_min");
|
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("TopDriveTorqueOffset")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("top_drive_torque_offset");
|
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("TopDriveTorqueSpFrom")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("top_drive_torque_sp_from")
|
|
|
|
|
.HasComment("Заданный момент c СВП");
|
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<short?>("TopDriveTorqueSpFromErr")
|
|
|
|
|
.HasColumnType("smallint")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("top_drive_torque_sp_from_err");
|
2021-09-07 14:04:30 +05:00
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("TopDriveTorqueSpFromMax")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("top_drive_torque_sp_from_max");
|
2021-09-07 14:04:30 +05:00
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("TopDriveTorqueSpFromMin")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("top_drive_torque_sp_from_min");
|
2021-09-07 14:04:30 +05:00
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("TopDriveTorqueSpFromOffset")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("top_drive_torque_sp_from_offset");
|
2021-09-07 14:04:30 +05:00
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("TopDriveTorqueSpTo")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("top_drive_torque_sp_to")
|
|
|
|
|
.HasComment("Задание момента на СВП");
|
2021-09-07 14:04:30 +05:00
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<short?>("TopDriveTorqueSpToErr")
|
|
|
|
|
.HasColumnType("smallint")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("top_drive_torque_sp_to_err");
|
2021-09-07 14:04:30 +05:00
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("TopDriveTorqueSpToMax")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("top_drive_torque_sp_to_max");
|
2021-09-07 14:04:30 +05:00
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("TopDriveTorqueSpToMin")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("top_drive_torque_sp_to_min");
|
2021-09-07 14:04:30 +05:00
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("TopDriveTorqueSpToOffset")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("top_drive_torque_sp_to_offset");
|
2021-09-07 14:04:30 +05:00
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("TorqueLeftLimit")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("torque_left_limit")
|
|
|
|
|
.HasComment("Ограничение крутящего момента влево");
|
2021-09-07 14:04:30 +05:00
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("TorqueRampTime")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("torque_ramp_time")
|
|
|
|
|
.HasComment("Время нарастания момента");
|
2021-09-07 14:04:30 +05:00
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("TorqueRightLimit")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("torque_right_limit")
|
|
|
|
|
.HasComment("Ограничение крутящего момента вправо");
|
2021-09-07 14:04:30 +05:00
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("TorqueStarting")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("torque_starting")
|
|
|
|
|
.HasComment(" Страгивающий момент");
|
2021-09-07 14:04:30 +05:00
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("TurnLeftOnceByAngle")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("turn_left_once_by_angle")
|
|
|
|
|
.HasComment("Доворот по градусам единожды влево");
|
2021-09-07 14:04:30 +05:00
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("TurnLeftOnceByRevols")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("turn_left_once_by_revols")
|
|
|
|
|
.HasComment("Доворот по оборотам единожды влево");
|
2021-09-07 14:04:30 +05:00
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("TurnLeftOnceByTorque")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("turn_left_once_by_torque")
|
|
|
|
|
.HasComment("Доворот по моменту единожды влево");
|
2021-09-07 14:04:30 +05:00
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("TurnRightOnceByAngle")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("turn_right_once_by_angle")
|
|
|
|
|
.HasComment("Доворот по градусам единожды вправо");
|
2021-09-07 14:04:30 +05:00
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("TurnRightOnceByRevols")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("turn_right_once_by_revols")
|
|
|
|
|
.HasComment("Доворот по оборотам единожды вправо");
|
2021-09-07 14:04:30 +05:00
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("TurnRightOnceByTorque")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("turn_right_once_by_torque")
|
|
|
|
|
.HasComment("Доворот по моменту единожды вправо");
|
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("UnlockBySectorOut")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("unlock_by_sector_out")
|
|
|
|
|
.HasComment(" Градус отклонения от сектора для автоматического сброса блокировки");
|
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<float?>("Ver")
|
|
|
|
|
.HasColumnType("real")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("ver")
|
|
|
|
|
.HasComment("Версия ПО ПЛК");
|
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<short?>("W2800")
|
|
|
|
|
.HasColumnType("smallint")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("w2800")
|
|
|
|
|
.HasComment("Установка нуля энкодера");
|
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<short?>("W2808")
|
|
|
|
|
.HasColumnType("smallint")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("w2808")
|
|
|
|
|
.HasComment("Неисправность энкодера");
|
|
|
|
|
|
2021-10-31 18:01:32 +05:00
|
|
|
|
b.Property<short?>("W2810")
|
|
|
|
|
.HasColumnType("smallint")
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasColumnName("w2810")
|
|
|
|
|
.HasComment(" автоматический сброс блокировки");
|
|
|
|
|
|
2021-11-13 18:47:11 +05:00
|
|
|
|
b.HasKey("IdTelemetry", "Date");
|
2021-09-07 14:04:30 +05:00
|
|
|
|
|
2021-09-14 17:17:33 +05:00
|
|
|
|
b.ToTable("t_telemetry_data_spin");
|
2021-09-07 14:04:30 +05:00
|
|
|
|
|
|
|
|
|
b
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.HasComment("набор основных данных по SpinMaster");
|
2021-09-07 14:04:30 +05:00
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("AsbCloudDb.Model.TelemetryEvent", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Property<int>("IdTelemetry")
|
|
|
|
|
.HasColumnType("integer")
|
|
|
|
|
.HasColumnName("id_telemetry");
|
|
|
|
|
|
|
|
|
|
b.Property<int>("IdEvent")
|
|
|
|
|
.HasColumnType("integer")
|
|
|
|
|
.HasColumnName("id_event");
|
|
|
|
|
|
|
|
|
|
b.Property<int>("IdCategory")
|
|
|
|
|
.HasColumnType("integer")
|
|
|
|
|
.HasColumnName("id_category");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("MessageTemplate")
|
|
|
|
|
.HasColumnType("text")
|
|
|
|
|
.HasColumnName("message_template");
|
|
|
|
|
|
|
|
|
|
b.HasKey("IdTelemetry", "IdEvent");
|
|
|
|
|
|
|
|
|
|
b.ToTable("t_telemetry_event");
|
|
|
|
|
|
|
|
|
|
b
|
|
|
|
|
.HasComment("Справочник событий. События формируют сообщения. Разделено по версиям посылок от телеметрии.");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("AsbCloudDb.Model.TelemetryMessage", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Property<int>("Id")
|
|
|
|
|
.ValueGeneratedOnAdd()
|
|
|
|
|
.HasColumnType("integer")
|
|
|
|
|
.HasColumnName("id")
|
2021-10-01 17:37:44 +05:00
|
|
|
|
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
2021-09-07 14:04:30 +05:00
|
|
|
|
|
|
|
|
|
b.Property<string>("Arg0")
|
|
|
|
|
.HasMaxLength(255)
|
|
|
|
|
.HasColumnType("character varying(255)")
|
|
|
|
|
.HasColumnName("arg0")
|
|
|
|
|
.HasComment("Аргумент №0 для вставки в шаблон сообщения");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("Arg1")
|
|
|
|
|
.HasMaxLength(255)
|
|
|
|
|
.HasColumnType("character varying(255)")
|
|
|
|
|
.HasColumnName("arg1");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("Arg2")
|
|
|
|
|
.HasMaxLength(255)
|
|
|
|
|
.HasColumnType("character varying(255)")
|
|
|
|
|
.HasColumnName("arg2");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("Arg3")
|
|
|
|
|
.HasMaxLength(255)
|
|
|
|
|
.HasColumnType("character varying(255)")
|
|
|
|
|
.HasColumnName("arg3");
|
|
|
|
|
|
|
|
|
|
b.Property<DateTime>("Date")
|
|
|
|
|
.HasColumnType("timestamp with time zone")
|
|
|
|
|
.HasColumnName("date");
|
|
|
|
|
|
|
|
|
|
b.Property<int>("IdEvent")
|
|
|
|
|
.HasColumnType("integer")
|
|
|
|
|
.HasColumnName("id_event");
|
|
|
|
|
|
|
|
|
|
b.Property<int>("IdTelemetry")
|
|
|
|
|
.HasColumnType("integer")
|
|
|
|
|
.HasColumnName("id_telemetry");
|
|
|
|
|
|
|
|
|
|
b.Property<int?>("IdTelemetryUser")
|
|
|
|
|
.HasColumnType("integer")
|
|
|
|
|
.HasColumnName("id_telemetry_user")
|
|
|
|
|
.HasComment("Пользователь панели отправляющей телеметрию. не пользователь облака.");
|
|
|
|
|
|
2021-09-17 16:24:01 +05:00
|
|
|
|
b.Property<double>("WellDepth")
|
|
|
|
|
.HasColumnType("double precision")
|
|
|
|
|
.HasColumnName("well_depth");
|
|
|
|
|
|
2021-09-07 14:04:30 +05:00
|
|
|
|
b.HasKey("Id");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("IdTelemetry");
|
|
|
|
|
|
|
|
|
|
b.ToTable("t_telemetry_message");
|
|
|
|
|
|
|
|
|
|
b
|
|
|
|
|
.HasComment("Сообщения на буровых");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("AsbCloudDb.Model.TelemetryUser", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Property<int>("IdTelemetry")
|
|
|
|
|
.HasColumnType("integer")
|
|
|
|
|
.HasColumnName("id_telemetry");
|
|
|
|
|
|
|
|
|
|
b.Property<int>("IdUser")
|
|
|
|
|
.HasColumnType("integer")
|
|
|
|
|
.HasColumnName("id_user");
|
|
|
|
|
|
|
|
|
|
b.Property<int?>("Level")
|
|
|
|
|
.HasColumnType("integer")
|
|
|
|
|
.HasColumnName("level");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("Name")
|
|
|
|
|
.HasMaxLength(255)
|
|
|
|
|
.HasColumnType("character varying(255)")
|
|
|
|
|
.HasColumnName("name");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("Patronymic")
|
|
|
|
|
.HasMaxLength(255)
|
|
|
|
|
.HasColumnType("character varying(255)")
|
|
|
|
|
.HasColumnName("patronymic");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("Surname")
|
|
|
|
|
.HasMaxLength(255)
|
|
|
|
|
.HasColumnType("character varying(255)")
|
|
|
|
|
.HasColumnName("surname");
|
|
|
|
|
|
|
|
|
|
b.HasKey("IdTelemetry", "IdUser");
|
|
|
|
|
|
|
|
|
|
b.ToTable("t_telemetry_user");
|
|
|
|
|
|
|
|
|
|
b
|
|
|
|
|
.HasComment("Пользователи панели САУБ. Для сообщений.");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("AsbCloudDb.Model.User", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Property<int>("Id")
|
|
|
|
|
.ValueGeneratedOnAdd()
|
|
|
|
|
.HasColumnType("integer")
|
|
|
|
|
.HasColumnName("id")
|
2021-10-01 17:37:44 +05:00
|
|
|
|
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
2021-09-07 14:04:30 +05:00
|
|
|
|
|
2021-09-07 14:42:56 +05:00
|
|
|
|
b.Property<string>("Email")
|
|
|
|
|
.HasMaxLength(255)
|
|
|
|
|
.HasColumnType("character varying(255)")
|
|
|
|
|
.HasColumnName("email")
|
|
|
|
|
.HasComment("должность");
|
|
|
|
|
|
2021-09-07 14:04:30 +05:00
|
|
|
|
b.Property<int?>("IdCompany")
|
|
|
|
|
.HasColumnType("integer")
|
|
|
|
|
.HasColumnName("id_company");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("Login")
|
|
|
|
|
.HasMaxLength(255)
|
|
|
|
|
.HasColumnType("character varying(255)")
|
|
|
|
|
.HasColumnName("login");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("Name")
|
|
|
|
|
.HasMaxLength(255)
|
|
|
|
|
.HasColumnType("character varying(255)")
|
|
|
|
|
.HasColumnName("name")
|
|
|
|
|
.HasComment("имя");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("PasswordHash")
|
|
|
|
|
.HasMaxLength(255)
|
|
|
|
|
.HasColumnType("character varying(255)")
|
|
|
|
|
.HasColumnName("password_hash")
|
|
|
|
|
.HasComment("соленый хэш пароля.\nпервые 5 символов - соль");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("Patronymic")
|
|
|
|
|
.HasMaxLength(255)
|
|
|
|
|
.HasColumnType("character varying(255)")
|
|
|
|
|
.HasColumnName("patronymic")
|
|
|
|
|
.HasComment("отчество");
|
|
|
|
|
|
2021-09-07 14:42:56 +05:00
|
|
|
|
b.Property<string>("Phone")
|
|
|
|
|
.HasMaxLength(50)
|
|
|
|
|
.HasColumnType("character varying(50)")
|
|
|
|
|
.HasColumnName("phone")
|
|
|
|
|
.HasComment("номер телефона");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("Position")
|
|
|
|
|
.HasMaxLength(255)
|
|
|
|
|
.HasColumnType("character varying(255)")
|
|
|
|
|
.HasColumnName("position")
|
|
|
|
|
.HasComment("email");
|
|
|
|
|
|
2021-09-07 14:04:30 +05:00
|
|
|
|
b.Property<short?>("State")
|
|
|
|
|
.HasColumnType("smallint")
|
|
|
|
|
.HasColumnName("state")
|
|
|
|
|
.HasComment("состояние:\n100 - удален");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("Surname")
|
|
|
|
|
.HasMaxLength(255)
|
|
|
|
|
.HasColumnType("character varying(255)")
|
|
|
|
|
.HasColumnName("surname")
|
|
|
|
|
.HasComment("фамилия");
|
|
|
|
|
|
|
|
|
|
b.HasKey("Id");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("IdCompany");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("Login")
|
|
|
|
|
.IsUnique();
|
|
|
|
|
|
|
|
|
|
b.ToTable("t_user");
|
|
|
|
|
|
|
|
|
|
b
|
|
|
|
|
.HasComment("Пользователи облака");
|
|
|
|
|
|
|
|
|
|
b.HasData(
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 1,
|
|
|
|
|
IdCompany = 1,
|
|
|
|
|
Login = "dev",
|
|
|
|
|
Name = "Разработчик",
|
|
|
|
|
PasswordHash = "Vlcj|4fa529103dde7ff72cfe76185f344d4aa87931f8e1b2044e8a7739947c3d18923464eaad93843e4f809c5e126d013072"
|
|
|
|
|
});
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("AsbCloudDb.Model.UserRole", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Property<int>("Id")
|
|
|
|
|
.ValueGeneratedOnAdd()
|
|
|
|
|
.HasColumnType("integer")
|
|
|
|
|
.HasColumnName("id")
|
2021-10-01 17:37:44 +05:00
|
|
|
|
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
2021-09-07 14:04:30 +05:00
|
|
|
|
|
|
|
|
|
b.Property<string>("Caption")
|
|
|
|
|
.HasMaxLength(255)
|
|
|
|
|
.HasColumnType("character varying(255)")
|
|
|
|
|
.HasColumnName("caption")
|
|
|
|
|
.HasComment("Название");
|
|
|
|
|
|
2021-11-24 11:30:29 +05:00
|
|
|
|
b.Property<int>("IdParent")
|
|
|
|
|
.HasColumnType("integer")
|
|
|
|
|
.HasColumnName("id_parent")
|
|
|
|
|
.HasComment("От какой роли унаследована данная роль");
|
|
|
|
|
|
|
|
|
|
b.Property<int>("RoleType")
|
|
|
|
|
.HasColumnType("integer")
|
|
|
|
|
.HasColumnName("role_type")
|
|
|
|
|
.HasComment("0-роль из стандартной матрицы, \n1-специальная роль для какого-либо пользователя");
|
|
|
|
|
|
2021-09-07 14:04:30 +05:00
|
|
|
|
b.HasKey("Id");
|
|
|
|
|
|
|
|
|
|
b.ToTable("t_user_role");
|
|
|
|
|
|
|
|
|
|
b
|
|
|
|
|
.HasComment("Роли пользователей в системе");
|
|
|
|
|
|
|
|
|
|
b.HasData(
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 1,
|
2021-11-24 11:30:29 +05:00
|
|
|
|
Caption = "Администратор",
|
|
|
|
|
IdParent = 0,
|
|
|
|
|
RoleType = 0
|
2021-09-07 14:04:30 +05:00
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 2,
|
2021-11-24 11:30:29 +05:00
|
|
|
|
Caption = "Пользователь",
|
|
|
|
|
IdParent = 0,
|
|
|
|
|
RoleType = 0
|
2021-09-07 14:04:30 +05:00
|
|
|
|
});
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("AsbCloudDb.Model.Well", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Property<int>("Id")
|
|
|
|
|
.ValueGeneratedOnAdd()
|
|
|
|
|
.HasColumnType("integer")
|
|
|
|
|
.HasColumnName("id")
|
2021-10-01 17:37:44 +05:00
|
|
|
|
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
2021-09-07 14:04:30 +05:00
|
|
|
|
|
|
|
|
|
b.Property<string>("Caption")
|
|
|
|
|
.HasMaxLength(255)
|
|
|
|
|
.HasColumnType("character varying(255)")
|
|
|
|
|
.HasColumnName("caption");
|
|
|
|
|
|
|
|
|
|
b.Property<int?>("IdCluster")
|
|
|
|
|
.HasColumnType("integer")
|
|
|
|
|
.HasColumnName("id_cluster");
|
|
|
|
|
|
2021-10-20 11:21:14 +05:00
|
|
|
|
b.Property<int>("IdState")
|
|
|
|
|
.HasColumnType("integer")
|
|
|
|
|
.HasColumnName("state")
|
|
|
|
|
.HasComment("0 - неизвестно, 1 - в работе, 2 - завершена");
|
|
|
|
|
|
2021-09-07 14:04:30 +05:00
|
|
|
|
b.Property<int?>("IdTelemetry")
|
|
|
|
|
.HasColumnType("integer")
|
|
|
|
|
.HasColumnName("id_telemetry");
|
|
|
|
|
|
|
|
|
|
b.Property<int?>("IdWellType")
|
|
|
|
|
.HasColumnType("integer")
|
|
|
|
|
.HasColumnName("id_well_type");
|
|
|
|
|
|
|
|
|
|
b.Property<double?>("Latitude")
|
|
|
|
|
.HasColumnType("double precision")
|
|
|
|
|
.HasColumnName("latitude");
|
|
|
|
|
|
|
|
|
|
b.Property<double?>("Longitude")
|
|
|
|
|
.HasColumnType("double precision")
|
|
|
|
|
.HasColumnName("longitude");
|
|
|
|
|
|
|
|
|
|
b.HasKey("Id");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("IdCluster");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("IdTelemetry")
|
|
|
|
|
.IsUnique();
|
|
|
|
|
|
|
|
|
|
b.HasIndex("IdWellType");
|
|
|
|
|
|
|
|
|
|
b.ToTable("t_well");
|
|
|
|
|
|
|
|
|
|
b
|
|
|
|
|
.HasComment("скважины");
|
|
|
|
|
});
|
|
|
|
|
|
2021-10-12 10:39:42 +05:00
|
|
|
|
modelBuilder.Entity("AsbCloudDb.Model.WellComposite", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Property<int>("IdWell")
|
|
|
|
|
.HasColumnType("integer")
|
|
|
|
|
.HasColumnName("id_well")
|
|
|
|
|
.HasComment("Id скважины получателя");
|
|
|
|
|
|
|
|
|
|
b.Property<int>("IdWellSrc")
|
|
|
|
|
.HasColumnType("integer")
|
|
|
|
|
.HasColumnName("id_well_src")
|
|
|
|
|
.HasComment("Id скважины композита");
|
|
|
|
|
|
|
|
|
|
b.Property<int>("IdWellSectionType")
|
|
|
|
|
.HasColumnType("integer")
|
|
|
|
|
.HasColumnName("id_well_section_type")
|
|
|
|
|
.HasComment("Id тип секции композита");
|
|
|
|
|
|
|
|
|
|
b.HasKey("IdWell", "IdWellSrc", "IdWellSectionType");
|
|
|
|
|
|
2021-10-14 14:46:20 +05:00
|
|
|
|
b.HasIndex("IdWellSectionType");
|
|
|
|
|
|
2021-10-12 10:39:42 +05:00
|
|
|
|
b.HasIndex("IdWellSrc");
|
|
|
|
|
|
|
|
|
|
b.ToTable("t_well_сomposite");
|
|
|
|
|
|
|
|
|
|
b
|
|
|
|
|
.HasComment("Композитная скважина");
|
|
|
|
|
});
|
|
|
|
|
|
2021-09-07 14:04:30 +05:00
|
|
|
|
modelBuilder.Entity("AsbCloudDb.Model.WellOperation", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Property<int>("Id")
|
|
|
|
|
.ValueGeneratedOnAdd()
|
|
|
|
|
.HasColumnType("integer")
|
|
|
|
|
.HasColumnName("id")
|
2021-10-01 17:37:44 +05:00
|
|
|
|
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
2021-09-07 14:04:30 +05:00
|
|
|
|
|
|
|
|
|
b.Property<string>("CategoryInfo")
|
|
|
|
|
.HasColumnType("text")
|
|
|
|
|
.HasColumnName("category_info")
|
|
|
|
|
.HasComment("Доп. информация к выбраной категории");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("Comment")
|
|
|
|
|
.HasColumnType("text")
|
|
|
|
|
.HasColumnName("comment")
|
|
|
|
|
.HasComment("Комментарий");
|
|
|
|
|
|
2021-10-08 11:30:06 +05:00
|
|
|
|
b.Property<DateTime>("DateStart")
|
|
|
|
|
.HasColumnType("timestamp without time zone")
|
|
|
|
|
.HasColumnName("date_start")
|
|
|
|
|
.HasComment("Дата начала операции");
|
|
|
|
|
|
2021-10-11 16:20:07 +05:00
|
|
|
|
b.Property<double>("DepthEnd")
|
|
|
|
|
.HasColumnType("double precision")
|
|
|
|
|
.HasColumnName("depth_end")
|
|
|
|
|
.HasComment("Глубина после завершения операции, м");
|
|
|
|
|
|
|
|
|
|
b.Property<double>("DepthStart")
|
|
|
|
|
.HasColumnType("double precision")
|
|
|
|
|
.HasColumnName("depth_start")
|
|
|
|
|
.HasComment("Глубина на начало операции, м");
|
|
|
|
|
|
2021-09-07 14:04:30 +05:00
|
|
|
|
b.Property<double>("DurationHours")
|
|
|
|
|
.HasColumnType("double precision")
|
|
|
|
|
.HasColumnName("duration_hours")
|
2021-10-08 11:30:06 +05:00
|
|
|
|
.HasComment("Продолжительность, часы");
|
2021-09-07 14:04:30 +05:00
|
|
|
|
|
|
|
|
|
b.Property<int>("IdCategory")
|
|
|
|
|
.HasColumnType("integer")
|
|
|
|
|
.HasColumnName("id_category")
|
|
|
|
|
.HasComment("Id категории операции");
|
|
|
|
|
|
|
|
|
|
b.Property<int>("IdType")
|
|
|
|
|
.HasColumnType("integer")
|
|
|
|
|
.HasColumnName("id_type")
|
|
|
|
|
.HasComment("0 = План или 1 = Факт");
|
|
|
|
|
|
|
|
|
|
b.Property<int>("IdWell")
|
|
|
|
|
.HasColumnType("integer")
|
|
|
|
|
.HasColumnName("id_well")
|
|
|
|
|
.HasComment("Id скважины");
|
|
|
|
|
|
|
|
|
|
b.Property<int>("IdWellSectionType")
|
|
|
|
|
.HasColumnType("integer")
|
|
|
|
|
.HasColumnName("id_well_section_type")
|
|
|
|
|
.HasComment("Id тип секции скважины");
|
|
|
|
|
|
|
|
|
|
b.HasKey("Id");
|
|
|
|
|
|
2021-10-08 11:30:06 +05:00
|
|
|
|
b.HasIndex("DateStart");
|
|
|
|
|
|
2021-10-11 16:20:07 +05:00
|
|
|
|
b.HasIndex("DepthEnd");
|
|
|
|
|
|
2021-09-07 14:04:30 +05:00
|
|
|
|
b.HasIndex("IdCategory");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("IdWell");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("IdWellSectionType");
|
|
|
|
|
|
|
|
|
|
b.ToTable("t_well_operation");
|
|
|
|
|
|
|
|
|
|
b
|
|
|
|
|
.HasComment("Данные по операциям на скважине");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("AsbCloudDb.Model.WellOperationCategory", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Property<int>("Id")
|
|
|
|
|
.ValueGeneratedOnAdd()
|
|
|
|
|
.HasColumnType("integer")
|
|
|
|
|
.HasColumnName("id")
|
2021-10-01 17:37:44 +05:00
|
|
|
|
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
2021-09-07 14:04:30 +05:00
|
|
|
|
|
|
|
|
|
b.Property<int>("Code")
|
|
|
|
|
.HasColumnType("integer")
|
|
|
|
|
.HasColumnName("code")
|
|
|
|
|
.HasComment("Код операции");
|
|
|
|
|
|
|
|
|
|
b.Property<string>("Name")
|
|
|
|
|
.HasColumnType("text")
|
|
|
|
|
.HasColumnName("name")
|
|
|
|
|
.HasComment("Название категории операции");
|
|
|
|
|
|
|
|
|
|
b.HasKey("Id");
|
|
|
|
|
|
|
|
|
|
b.ToTable("t_well_operation_category");
|
|
|
|
|
|
|
|
|
|
b
|
|
|
|
|
.HasComment("Справочник операций на скважине");
|
|
|
|
|
|
|
|
|
|
b.HasData(
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 1,
|
|
|
|
|
Code = 0,
|
|
|
|
|
Name = "Невозможно определить операцию"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 2,
|
|
|
|
|
Code = 0,
|
|
|
|
|
Name = "Роторное бурение"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 3,
|
|
|
|
|
Code = 0,
|
|
|
|
|
Name = "Слайдирование"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 4,
|
|
|
|
|
Code = 0,
|
|
|
|
|
Name = "Подъем с проработкой"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 5,
|
|
|
|
|
Code = 0,
|
|
|
|
|
Name = "Спуск с проработкой"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 6,
|
|
|
|
|
Code = 0,
|
|
|
|
|
Name = "Подъем с промывкой"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 7,
|
|
|
|
|
Code = 0,
|
|
|
|
|
Name = "Спуск с промывкой"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 8,
|
|
|
|
|
Code = 0,
|
|
|
|
|
Name = "Спуск в скважину"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 9,
|
|
|
|
|
Code = 0,
|
|
|
|
|
Name = "Спуск с вращением"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 10,
|
|
|
|
|
Code = 0,
|
|
|
|
|
Name = "Подъем из скважины"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 11,
|
|
|
|
|
Code = 0,
|
|
|
|
|
Name = "Подъем с вращением"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 12,
|
|
|
|
|
Code = 0,
|
|
|
|
|
Name = "Промывка в покое"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 13,
|
|
|
|
|
Code = 0,
|
|
|
|
|
Name = "Промывка с вращением"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 14,
|
|
|
|
|
Code = 0,
|
|
|
|
|
Name = "Удержание в клиньях"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 15,
|
|
|
|
|
Code = 0,
|
|
|
|
|
Name = "Неподвижное состояние"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 16,
|
|
|
|
|
Code = 0,
|
|
|
|
|
Name = "Вращение без циркуляции"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 17,
|
|
|
|
|
Code = 0,
|
|
|
|
|
Name = "На поверхности"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 1001,
|
|
|
|
|
Code = 0,
|
2021-10-19 10:34:11 +05:00
|
|
|
|
Name = "Бурение"
|
2021-09-07 14:04:30 +05:00
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 1002,
|
|
|
|
|
Code = 0,
|
|
|
|
|
Name = "ГИС"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 1003,
|
|
|
|
|
Code = 0,
|
|
|
|
|
Name = "ГФР"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 1004,
|
|
|
|
|
Code = 0,
|
|
|
|
|
Name = "Монтаж ПВО"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 1005,
|
|
|
|
|
Code = 0,
|
|
|
|
|
Name = "Демонтаж ПВО"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 1006,
|
|
|
|
|
Code = 0,
|
|
|
|
|
Name = "Установка ФА"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 1007,
|
|
|
|
|
Code = 0,
|
|
|
|
|
Name = "Оборудование устья"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 1008,
|
|
|
|
|
Code = 0,
|
|
|
|
|
Name = "ОЗЦ"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 1009,
|
|
|
|
|
Code = 0,
|
|
|
|
|
Name = "Оборудование устья"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 1010,
|
|
|
|
|
Code = 0,
|
|
|
|
|
Name = "ОЗЦ"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 1011,
|
|
|
|
|
Code = 0,
|
|
|
|
|
Name = "Начало цикла строительства скважины"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 1012,
|
|
|
|
|
Code = 0,
|
|
|
|
|
Name = "Окончание цикла строительства скважины"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 1013,
|
|
|
|
|
Code = 0,
|
|
|
|
|
Name = "Опрессовка ПВО"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 1014,
|
|
|
|
|
Code = 0,
|
|
|
|
|
Name = "Опресовка Ц.К."
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 1015,
|
|
|
|
|
Code = 0,
|
|
|
|
|
Name = "Опрессовка ВЗД"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 1016,
|
|
|
|
|
Code = 0,
|
|
|
|
|
Name = "Перевод скв на другой тип промывочной жидкости"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 1017,
|
|
|
|
|
Code = 0,
|
|
|
|
|
Name = "Перезапись каротажа"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 1018,
|
|
|
|
|
Code = 0,
|
|
|
|
|
Name = "Перетяжка талевого каната"
|
|
|
|
|
},
|
|
|
|
|
new
|
2021-10-06 18:06:07 +05:00
|
|
|
|
{
|
|
|
|
|
Id = 1019,
|
|
|
|
|
Code = 0,
|
|
|
|
|
Name = "Наращивание, промывка"
|
|
|
|
|
},
|
|
|
|
|
new
|
2021-09-07 14:04:30 +05:00
|
|
|
|
{
|
|
|
|
|
Id = 1020,
|
|
|
|
|
Code = 0,
|
|
|
|
|
Name = "Подъем инструмента"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 1021,
|
|
|
|
|
Code = 0,
|
|
|
|
|
Name = "Подъем инструмента с промывкой"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 1022,
|
|
|
|
|
Code = 0,
|
|
|
|
|
Name = "Обратная проработка"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 1023,
|
|
|
|
|
Code = 0,
|
|
|
|
|
Name = "Сборка инструмента"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 1024,
|
|
|
|
|
Code = 0,
|
|
|
|
|
Name = "Подготовительные работы"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 1025,
|
|
|
|
|
Code = 0,
|
|
|
|
|
Name = "Сборка КНБК"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 1026,
|
|
|
|
|
Code = 0,
|
|
|
|
|
Name = "Разборка КНБК"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 1027,
|
|
|
|
|
Code = 0,
|
|
|
|
|
Name = "Промывка"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 1028,
|
|
|
|
|
Code = 0,
|
|
|
|
|
Name = "Промежуточная промывка"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 1029,
|
|
|
|
|
Code = 0,
|
|
|
|
|
Name = "Прокачка пачек"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 1030,
|
|
|
|
|
Code = 0,
|
|
|
|
|
Name = "Разбуривание тех.оснастки"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 1031,
|
|
|
|
|
Code = 0,
|
|
|
|
|
Name = "Ремонт"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 1032,
|
|
|
|
|
Code = 0,
|
|
|
|
|
Name = "Спуск инструмента"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 1033,
|
|
|
|
|
Code = 0,
|
|
|
|
|
Name = "Спуск инструмента с промывкой"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 1034,
|
|
|
|
|
Code = 0,
|
|
|
|
|
Name = "Прямая проработка"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 1035,
|
|
|
|
|
Code = 0,
|
|
|
|
|
Name = "Принудительная проработка"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 1036,
|
|
|
|
|
Code = 0,
|
|
|
|
|
Name = "Спуск обсадной колонны"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 1037,
|
|
|
|
|
Code = 0,
|
|
|
|
|
Name = "Тех СПО-подъем"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 1038,
|
|
|
|
|
Code = 0,
|
|
|
|
|
Name = "Тех СПО-спуск"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 1039,
|
|
|
|
|
Code = 0,
|
|
|
|
|
Name = "Техническое обслуживание"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 1040,
|
|
|
|
|
Code = 0,
|
|
|
|
|
Name = "Цементаж"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 1041,
|
|
|
|
|
Code = 0,
|
|
|
|
|
Name = "Шаблонировка ствола"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 1042,
|
|
|
|
|
Code = 0,
|
|
|
|
|
Name = "Геологическое осложнение"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 1043,
|
|
|
|
|
Code = 0,
|
|
|
|
|
Name = "НПВ"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 1044,
|
|
|
|
|
Code = 0,
|
|
|
|
|
Name = "ВМР"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 1045,
|
|
|
|
|
Code = 0,
|
|
|
|
|
Name = "Прочее"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 1046,
|
|
|
|
|
Code = 0,
|
|
|
|
|
Name = "Спуск КНБК"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 1047,
|
|
|
|
|
Code = 0,
|
|
|
|
|
Name = "Подъем КНБК"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 1048,
|
|
|
|
|
Code = 0,
|
|
|
|
|
Name = "Спуск ОК"
|
2021-09-13 09:39:11 +05:00
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 1050,
|
|
|
|
|
Code = 0,
|
|
|
|
|
Name = "Промывка при спуске ОК"
|
2021-09-07 14:04:30 +05:00
|
|
|
|
});
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("AsbCloudDb.Model.WellSectionType", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Property<int>("Id")
|
|
|
|
|
.ValueGeneratedOnAdd()
|
|
|
|
|
.HasColumnType("integer")
|
|
|
|
|
.HasColumnName("id")
|
2021-10-01 17:37:44 +05:00
|
|
|
|
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
2021-09-07 14:04:30 +05:00
|
|
|
|
|
|
|
|
|
b.Property<string>("Caption")
|
|
|
|
|
.HasMaxLength(255)
|
|
|
|
|
.HasColumnType("character varying(255)")
|
|
|
|
|
.HasColumnName("caption")
|
|
|
|
|
.HasComment("Название");
|
|
|
|
|
|
|
|
|
|
b.HasKey("Id");
|
|
|
|
|
|
|
|
|
|
b.ToTable("t_well_section_type");
|
|
|
|
|
|
|
|
|
|
b
|
|
|
|
|
.HasComment("конструкция секции скважины");
|
|
|
|
|
|
|
|
|
|
b.HasData(
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 1,
|
|
|
|
|
Caption = "Пилотный ствол"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 2,
|
|
|
|
|
Caption = "Направление"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 3,
|
|
|
|
|
Caption = "Кондуктор"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 4,
|
|
|
|
|
Caption = "Эксплуатационная колонна"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 5,
|
|
|
|
|
Caption = "Транспортный ствол"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 6,
|
|
|
|
|
Caption = "Хвостовик"
|
|
|
|
|
});
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("AsbCloudDb.Model.WellType", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Property<int>("Id")
|
|
|
|
|
.ValueGeneratedOnAdd()
|
|
|
|
|
.HasColumnType("integer")
|
|
|
|
|
.HasColumnName("id")
|
2021-10-01 17:37:44 +05:00
|
|
|
|
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
2021-09-07 14:04:30 +05:00
|
|
|
|
|
|
|
|
|
b.Property<string>("Caption")
|
|
|
|
|
.HasMaxLength(255)
|
|
|
|
|
.HasColumnType("character varying(255)")
|
|
|
|
|
.HasColumnName("caption")
|
|
|
|
|
.HasComment("Название");
|
|
|
|
|
|
|
|
|
|
b.HasKey("Id");
|
|
|
|
|
|
|
|
|
|
b.ToTable("t_well_type");
|
|
|
|
|
|
|
|
|
|
b
|
|
|
|
|
.HasComment("конструкция скважины");
|
|
|
|
|
|
|
|
|
|
b.HasData(
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 1,
|
|
|
|
|
Caption = "Наклонно-направленная"
|
|
|
|
|
},
|
|
|
|
|
new
|
|
|
|
|
{
|
|
|
|
|
Id = 2,
|
|
|
|
|
Caption = "Горизонтальная"
|
|
|
|
|
});
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("AsbCloudDb.Model.Cluster", b =>
|
|
|
|
|
{
|
|
|
|
|
b.HasOne("AsbCloudDb.Model.Deposit", "Deposit")
|
|
|
|
|
.WithMany("Clusters")
|
|
|
|
|
.HasForeignKey("IdDeposit")
|
|
|
|
|
.HasConstraintName("t_cluster_t_deposit_id_fk");
|
|
|
|
|
|
|
|
|
|
b.Navigation("Deposit");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("AsbCloudDb.Model.Company", b =>
|
|
|
|
|
{
|
|
|
|
|
b.HasOne("AsbCloudDb.Model.CompanyType", "CompanyType")
|
|
|
|
|
.WithMany("Companies")
|
|
|
|
|
.HasForeignKey("IdCompanyType")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
|
|
|
.IsRequired();
|
|
|
|
|
|
|
|
|
|
b.Navigation("CompanyType");
|
|
|
|
|
});
|
|
|
|
|
|
2021-10-14 14:46:20 +05:00
|
|
|
|
modelBuilder.Entity("AsbCloudDb.Model.DrillFlowChart", b =>
|
2021-10-13 17:34:32 +05:00
|
|
|
|
{
|
|
|
|
|
b.HasOne("AsbCloudDb.Model.Well", "Well")
|
|
|
|
|
.WithMany()
|
|
|
|
|
.HasForeignKey("IdWell")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
|
|
|
.IsRequired();
|
|
|
|
|
|
|
|
|
|
b.Navigation("Well");
|
|
|
|
|
});
|
|
|
|
|
|
2021-10-11 16:20:07 +05:00
|
|
|
|
modelBuilder.Entity("AsbCloudDb.Model.DrillParams", b =>
|
|
|
|
|
{
|
|
|
|
|
b.HasOne("AsbCloudDb.Model.Well", "Well")
|
|
|
|
|
.WithMany()
|
|
|
|
|
.HasForeignKey("IdWell")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
|
|
|
.IsRequired();
|
|
|
|
|
|
|
|
|
|
b.HasOne("AsbCloudDb.Model.WellSectionType", "WellSectionType")
|
|
|
|
|
.WithMany("DrillParamsCollection")
|
|
|
|
|
.HasForeignKey("IdWellSectionType")
|
|
|
|
|
.HasConstraintName("t_drill_params_t_well_section_type_id_fk")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
|
|
|
.IsRequired();
|
|
|
|
|
|
|
|
|
|
b.Navigation("Well");
|
|
|
|
|
|
|
|
|
|
b.Navigation("WellSectionType");
|
|
|
|
|
});
|
|
|
|
|
|
2021-09-07 14:04:30 +05:00
|
|
|
|
modelBuilder.Entity("AsbCloudDb.Model.FileInfo", b =>
|
|
|
|
|
{
|
|
|
|
|
b.HasOne("AsbCloudDb.Model.User", "Author")
|
|
|
|
|
.WithMany("Files")
|
|
|
|
|
.HasForeignKey("IdAuthor");
|
|
|
|
|
|
|
|
|
|
b.HasOne("AsbCloudDb.Model.FileCategory", "FileCategory")
|
|
|
|
|
.WithMany()
|
|
|
|
|
.HasForeignKey("IdCategory")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
|
|
|
.IsRequired();
|
|
|
|
|
|
|
|
|
|
b.HasOne("AsbCloudDb.Model.Well", "Well")
|
|
|
|
|
.WithMany()
|
|
|
|
|
.HasForeignKey("IdWell")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
|
|
|
.IsRequired();
|
|
|
|
|
|
|
|
|
|
b.Navigation("Author");
|
|
|
|
|
|
|
|
|
|
b.Navigation("FileCategory");
|
|
|
|
|
|
|
|
|
|
b.Navigation("Well");
|
|
|
|
|
});
|
|
|
|
|
|
2021-11-01 16:41:25 +05:00
|
|
|
|
modelBuilder.Entity("AsbCloudDb.Model.FileMark", b =>
|
|
|
|
|
{
|
|
|
|
|
b.HasOne("AsbCloudDb.Model.FileInfo", "FileInfo")
|
|
|
|
|
.WithMany("FileMarks")
|
|
|
|
|
.HasForeignKey("IdFile")
|
|
|
|
|
.HasConstraintName("t_file_mark_t_file_info_fk")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
|
|
|
.IsRequired();
|
|
|
|
|
|
2021-11-13 18:47:11 +05:00
|
|
|
|
b.HasOne("AsbCloudDb.Model.User", "User")
|
2021-11-01 16:41:25 +05:00
|
|
|
|
.WithMany("FileMarks")
|
|
|
|
|
.HasForeignKey("IdUser")
|
|
|
|
|
.HasConstraintName("t_user_t_file_mark_fk")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
|
|
|
.IsRequired();
|
|
|
|
|
|
|
|
|
|
b.Navigation("FileInfo");
|
2021-11-13 18:47:11 +05:00
|
|
|
|
|
|
|
|
|
b.Navigation("User");
|
2021-11-01 16:41:25 +05:00
|
|
|
|
});
|
|
|
|
|
|
2021-09-07 14:04:30 +05:00
|
|
|
|
modelBuilder.Entity("AsbCloudDb.Model.Measure", b =>
|
|
|
|
|
{
|
|
|
|
|
b.HasOne("AsbCloudDb.Model.MeasureCategory", "Category")
|
|
|
|
|
.WithMany("Measures")
|
|
|
|
|
.HasForeignKey("IdCategory")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
|
|
|
.IsRequired();
|
|
|
|
|
|
|
|
|
|
b.HasOne("AsbCloudDb.Model.Well", "Well")
|
|
|
|
|
.WithMany()
|
|
|
|
|
.HasForeignKey("IdWell")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
|
|
|
.IsRequired();
|
|
|
|
|
|
|
|
|
|
b.Navigation("Category");
|
|
|
|
|
|
|
|
|
|
b.Navigation("Well");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("AsbCloudDb.Model.RelationCompanyWell", b =>
|
|
|
|
|
{
|
|
|
|
|
b.HasOne("AsbCloudDb.Model.Company", "Company")
|
|
|
|
|
.WithMany("RelationCompaniesWells")
|
|
|
|
|
.HasForeignKey("IdCompany")
|
|
|
|
|
.HasConstraintName("t_relation_company_well_t_company_id_fk")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
|
|
|
.IsRequired();
|
|
|
|
|
|
|
|
|
|
b.HasOne("AsbCloudDb.Model.Well", "Well")
|
|
|
|
|
.WithMany("RelationCompaniesWells")
|
|
|
|
|
.HasForeignKey("IdWell")
|
|
|
|
|
.HasConstraintName("t_relation_company_well_t_well_id_fk")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
|
|
|
.IsRequired();
|
|
|
|
|
|
|
|
|
|
b.Navigation("Company");
|
|
|
|
|
|
|
|
|
|
b.Navigation("Well");
|
|
|
|
|
});
|
|
|
|
|
|
2021-11-29 12:39:28 +05:00
|
|
|
|
modelBuilder.Entity("AsbCloudDb.Model.RelationUserRolePermission", b =>
|
|
|
|
|
{
|
|
|
|
|
b.HasOne("AsbCloudDb.Model.Permission", "Permission")
|
|
|
|
|
.WithMany("RelationUserRolesPermissions")
|
|
|
|
|
.HasForeignKey("IdPermission")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
|
|
|
.IsRequired();
|
|
|
|
|
|
|
|
|
|
b.HasOne("AsbCloudDb.Model.UserRole", "UserRole")
|
|
|
|
|
.WithMany("RelationUserRolesPermissions")
|
|
|
|
|
.HasForeignKey("IdUserRole")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
|
|
|
.IsRequired();
|
|
|
|
|
|
|
|
|
|
b.Navigation("Permission");
|
|
|
|
|
|
|
|
|
|
b.Navigation("UserRole");
|
|
|
|
|
});
|
|
|
|
|
|
2021-11-24 11:30:29 +05:00
|
|
|
|
modelBuilder.Entity("AsbCloudDb.Model.RelationUserUserRole", b =>
|
|
|
|
|
{
|
|
|
|
|
b.HasOne("AsbCloudDb.Model.User", "User")
|
|
|
|
|
.WithMany("RelationUsersUserRoles")
|
|
|
|
|
.HasForeignKey("IdUser")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
|
|
|
.IsRequired();
|
|
|
|
|
|
|
|
|
|
b.HasOne("AsbCloudDb.Model.UserRole", "UserRole")
|
|
|
|
|
.WithMany("RelationUsersUserRoles")
|
|
|
|
|
.HasForeignKey("IdUserRole")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
|
|
|
.IsRequired();
|
|
|
|
|
|
|
|
|
|
b.Navigation("User");
|
|
|
|
|
|
|
|
|
|
b.Navigation("UserRole");
|
|
|
|
|
});
|
|
|
|
|
|
2021-09-07 14:04:30 +05:00
|
|
|
|
modelBuilder.Entity("AsbCloudDb.Model.ReportProperty", b =>
|
|
|
|
|
{
|
|
|
|
|
b.HasOne("AsbCloudDb.Model.FileInfo", "File")
|
|
|
|
|
.WithMany()
|
|
|
|
|
.HasForeignKey("IdFile")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
|
|
|
.IsRequired();
|
|
|
|
|
|
|
|
|
|
b.HasOne("AsbCloudDb.Model.Well", "Well")
|
|
|
|
|
.WithMany()
|
|
|
|
|
.HasForeignKey("IdWell")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
|
|
|
.IsRequired();
|
|
|
|
|
|
|
|
|
|
b.Navigation("File");
|
|
|
|
|
|
|
|
|
|
b.Navigation("Well");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("AsbCloudDb.Model.TelemetryAnalysis", b =>
|
|
|
|
|
{
|
|
|
|
|
b.HasOne("AsbCloudDb.Model.WellOperationCategory", "Operation")
|
|
|
|
|
.WithMany("Analysis")
|
|
|
|
|
.HasForeignKey("IdOperation")
|
|
|
|
|
.HasConstraintName("t_analysis_t_operation_id_fk")
|
|
|
|
|
.OnDelete(DeleteBehavior.SetNull)
|
|
|
|
|
.IsRequired();
|
|
|
|
|
|
|
|
|
|
b.HasOne("AsbCloudDb.Model.Telemetry", "Telemetry")
|
|
|
|
|
.WithMany("Analysis")
|
|
|
|
|
.HasForeignKey("IdTelemetry")
|
|
|
|
|
.HasConstraintName("t_analysis_t_telemetry_id_fk")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
|
|
|
.IsRequired();
|
|
|
|
|
|
|
|
|
|
b.Navigation("Operation");
|
|
|
|
|
|
|
|
|
|
b.Navigation("Telemetry");
|
|
|
|
|
});
|
|
|
|
|
|
2021-09-14 17:17:33 +05:00
|
|
|
|
modelBuilder.Entity("AsbCloudDb.Model.TelemetryDataSaub", b =>
|
|
|
|
|
{
|
|
|
|
|
b.HasOne("AsbCloudDb.Model.Telemetry", "Telemetry")
|
|
|
|
|
.WithMany("DataSaub")
|
|
|
|
|
.HasForeignKey("IdTelemetry")
|
2021-09-17 16:24:01 +05:00
|
|
|
|
.HasConstraintName("t_telemetry_data_saub_t_telemetry_id_fk")
|
2021-10-01 17:37:44 +05:00
|
|
|
|
.OnDelete(DeleteBehavior.Cascade)
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.IsRequired();
|
|
|
|
|
|
|
|
|
|
b.Navigation("Telemetry");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("AsbCloudDb.Model.TelemetryDataSpin", b =>
|
|
|
|
|
{
|
|
|
|
|
b.HasOne("AsbCloudDb.Model.Telemetry", "Telemetry")
|
|
|
|
|
.WithMany("DataSpin")
|
|
|
|
|
.HasForeignKey("IdTelemetry")
|
2021-09-17 16:24:01 +05:00
|
|
|
|
.HasConstraintName("t_telemetry_data_spin_t_telemetry_id_fk")
|
2021-10-01 17:37:44 +05:00
|
|
|
|
.OnDelete(DeleteBehavior.Cascade)
|
2021-09-14 17:17:33 +05:00
|
|
|
|
.IsRequired();
|
|
|
|
|
|
|
|
|
|
b.Navigation("Telemetry");
|
|
|
|
|
});
|
|
|
|
|
|
2021-09-07 14:04:30 +05:00
|
|
|
|
modelBuilder.Entity("AsbCloudDb.Model.TelemetryEvent", b =>
|
|
|
|
|
{
|
|
|
|
|
b.HasOne("AsbCloudDb.Model.Telemetry", "Telemetry")
|
|
|
|
|
.WithMany("Events")
|
|
|
|
|
.HasForeignKey("IdTelemetry")
|
|
|
|
|
.HasConstraintName("t_event_t_telemetry_id_fk")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
|
|
|
.IsRequired();
|
|
|
|
|
|
|
|
|
|
b.Navigation("Telemetry");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("AsbCloudDb.Model.TelemetryMessage", b =>
|
|
|
|
|
{
|
|
|
|
|
b.HasOne("AsbCloudDb.Model.Telemetry", "Telemetry")
|
|
|
|
|
.WithMany("Messages")
|
|
|
|
|
.HasForeignKey("IdTelemetry")
|
|
|
|
|
.HasConstraintName("t_messages_t_telemetry_id_fk")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
|
|
|
.IsRequired();
|
|
|
|
|
|
|
|
|
|
b.Navigation("Telemetry");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("AsbCloudDb.Model.TelemetryUser", b =>
|
|
|
|
|
{
|
|
|
|
|
b.HasOne("AsbCloudDb.Model.Telemetry", "Telemetry")
|
|
|
|
|
.WithMany("Users")
|
|
|
|
|
.HasForeignKey("IdTelemetry")
|
|
|
|
|
.HasConstraintName("t_telemetry_user_t_telemetry_id_fk")
|
2021-10-01 17:37:44 +05:00
|
|
|
|
.OnDelete(DeleteBehavior.Cascade)
|
2021-09-07 14:04:30 +05:00
|
|
|
|
.IsRequired();
|
|
|
|
|
|
|
|
|
|
b.Navigation("Telemetry");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("AsbCloudDb.Model.User", b =>
|
|
|
|
|
{
|
|
|
|
|
b.HasOne("AsbCloudDb.Model.Company", "Company")
|
|
|
|
|
.WithMany("Users")
|
|
|
|
|
.HasForeignKey("IdCompany")
|
2021-10-01 17:37:44 +05:00
|
|
|
|
.HasConstraintName("t_user_t_company_id_fk")
|
|
|
|
|
.OnDelete(DeleteBehavior.SetNull);
|
2021-09-07 14:04:30 +05:00
|
|
|
|
|
|
|
|
|
b.Navigation("Company");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("AsbCloudDb.Model.Well", b =>
|
|
|
|
|
{
|
|
|
|
|
b.HasOne("AsbCloudDb.Model.Cluster", "Cluster")
|
|
|
|
|
.WithMany("Wells")
|
|
|
|
|
.HasForeignKey("IdCluster")
|
|
|
|
|
.HasConstraintName("t_well_t_cluster_id_fk");
|
|
|
|
|
|
|
|
|
|
b.HasOne("AsbCloudDb.Model.Telemetry", "Telemetry")
|
|
|
|
|
.WithOne("Well")
|
|
|
|
|
.HasForeignKey("AsbCloudDb.Model.Well", "IdTelemetry")
|
2021-10-01 17:37:44 +05:00
|
|
|
|
.HasConstraintName("t_well_t_telemetry_id_fk")
|
|
|
|
|
.OnDelete(DeleteBehavior.SetNull);
|
2021-09-07 14:04:30 +05:00
|
|
|
|
|
|
|
|
|
b.HasOne("AsbCloudDb.Model.WellType", "WellType")
|
|
|
|
|
.WithMany("Wells")
|
|
|
|
|
.HasForeignKey("IdWellType");
|
|
|
|
|
|
|
|
|
|
b.Navigation("Cluster");
|
|
|
|
|
|
|
|
|
|
b.Navigation("Telemetry");
|
|
|
|
|
|
|
|
|
|
b.Navigation("WellType");
|
|
|
|
|
});
|
|
|
|
|
|
2021-10-12 10:39:42 +05:00
|
|
|
|
modelBuilder.Entity("AsbCloudDb.Model.WellComposite", b =>
|
|
|
|
|
{
|
|
|
|
|
b.HasOne("AsbCloudDb.Model.Well", "Well")
|
|
|
|
|
.WithMany("WellComposites")
|
|
|
|
|
.HasForeignKey("IdWell")
|
|
|
|
|
.HasConstraintName("t_well_сomposite_t_well_id_fk")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
|
|
|
.IsRequired();
|
|
|
|
|
|
2021-10-14 14:46:20 +05:00
|
|
|
|
b.HasOne("AsbCloudDb.Model.WellSectionType", "WellSectionType")
|
|
|
|
|
.WithMany("WellComposites")
|
|
|
|
|
.HasForeignKey("IdWellSectionType")
|
|
|
|
|
.HasConstraintName("t_well_сomposite_t_well_section_type_id_fk")
|
2021-10-12 10:39:42 +05:00
|
|
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
|
|
|
.IsRequired();
|
|
|
|
|
|
2021-10-14 14:46:20 +05:00
|
|
|
|
b.HasOne("AsbCloudDb.Model.Well", "WellSrc")
|
|
|
|
|
.WithMany("WellCompositeSrcs")
|
2021-10-12 10:39:42 +05:00
|
|
|
|
.HasForeignKey("IdWellSrc")
|
2021-10-14 14:46:20 +05:00
|
|
|
|
.HasConstraintName("t_well_сomposite_src_t_well_id_fk")
|
2021-10-12 10:39:42 +05:00
|
|
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
|
|
|
.IsRequired();
|
|
|
|
|
|
|
|
|
|
b.Navigation("Well");
|
|
|
|
|
|
|
|
|
|
b.Navigation("WellSectionType");
|
|
|
|
|
|
|
|
|
|
b.Navigation("WellSrc");
|
|
|
|
|
});
|
|
|
|
|
|
2021-09-07 14:04:30 +05:00
|
|
|
|
modelBuilder.Entity("AsbCloudDb.Model.WellOperation", b =>
|
|
|
|
|
{
|
|
|
|
|
b.HasOne("AsbCloudDb.Model.WellOperationCategory", "OperationCategory")
|
|
|
|
|
.WithMany()
|
|
|
|
|
.HasForeignKey("IdCategory")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
|
|
|
.IsRequired();
|
|
|
|
|
|
|
|
|
|
b.HasOne("AsbCloudDb.Model.Well", "Well")
|
|
|
|
|
.WithMany("WellOperations")
|
|
|
|
|
.HasForeignKey("IdWell")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
|
|
|
.IsRequired();
|
|
|
|
|
|
|
|
|
|
b.HasOne("AsbCloudDb.Model.WellSectionType", "WellSectionType")
|
|
|
|
|
.WithMany("WellOperations")
|
|
|
|
|
.HasForeignKey("IdWellSectionType")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
|
|
|
.IsRequired();
|
|
|
|
|
|
|
|
|
|
b.Navigation("OperationCategory");
|
|
|
|
|
|
|
|
|
|
b.Navigation("Well");
|
|
|
|
|
|
|
|
|
|
b.Navigation("WellSectionType");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("AsbCloudDb.Model.Cluster", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Navigation("Wells");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("AsbCloudDb.Model.Company", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Navigation("RelationCompaniesWells");
|
|
|
|
|
|
|
|
|
|
b.Navigation("Users");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("AsbCloudDb.Model.CompanyType", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Navigation("Companies");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("AsbCloudDb.Model.Deposit", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Navigation("Clusters");
|
|
|
|
|
});
|
|
|
|
|
|
2021-11-01 16:41:25 +05:00
|
|
|
|
modelBuilder.Entity("AsbCloudDb.Model.FileInfo", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Navigation("FileMarks");
|
|
|
|
|
});
|
|
|
|
|
|
2021-09-07 14:04:30 +05:00
|
|
|
|
modelBuilder.Entity("AsbCloudDb.Model.MeasureCategory", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Navigation("Measures");
|
|
|
|
|
});
|
|
|
|
|
|
2021-11-29 12:39:28 +05:00
|
|
|
|
modelBuilder.Entity("AsbCloudDb.Model.Permission", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Navigation("RelationUserRolesPermissions");
|
|
|
|
|
});
|
|
|
|
|
|
2021-09-07 14:04:30 +05:00
|
|
|
|
modelBuilder.Entity("AsbCloudDb.Model.Telemetry", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Navigation("Analysis");
|
|
|
|
|
|
2021-09-14 17:17:33 +05:00
|
|
|
|
b.Navigation("DataSaub");
|
|
|
|
|
|
|
|
|
|
b.Navigation("DataSpin");
|
2021-09-07 14:04:30 +05:00
|
|
|
|
|
|
|
|
|
b.Navigation("Events");
|
|
|
|
|
|
|
|
|
|
b.Navigation("Messages");
|
|
|
|
|
|
|
|
|
|
b.Navigation("Users");
|
|
|
|
|
|
|
|
|
|
b.Navigation("Well");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("AsbCloudDb.Model.User", b =>
|
|
|
|
|
{
|
2021-11-01 16:41:25 +05:00
|
|
|
|
b.Navigation("FileMarks");
|
|
|
|
|
|
2021-09-07 14:04:30 +05:00
|
|
|
|
b.Navigation("Files");
|
2021-11-24 11:30:29 +05:00
|
|
|
|
|
|
|
|
|
b.Navigation("RelationUsersUserRoles");
|
2021-09-07 14:04:30 +05:00
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("AsbCloudDb.Model.UserRole", b =>
|
|
|
|
|
{
|
2021-11-29 12:39:28 +05:00
|
|
|
|
b.Navigation("RelationUserRolesPermissions");
|
|
|
|
|
|
2021-11-24 11:30:29 +05:00
|
|
|
|
b.Navigation("RelationUsersUserRoles");
|
2021-09-07 14:04:30 +05:00
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("AsbCloudDb.Model.Well", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Navigation("RelationCompaniesWells");
|
|
|
|
|
|
2021-10-12 10:39:42 +05:00
|
|
|
|
b.Navigation("WellComposites");
|
|
|
|
|
|
|
|
|
|
b.Navigation("WellCompositeSrcs");
|
|
|
|
|
|
2021-09-07 14:04:30 +05:00
|
|
|
|
b.Navigation("WellOperations");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("AsbCloudDb.Model.WellOperationCategory", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Navigation("Analysis");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("AsbCloudDb.Model.WellSectionType", b =>
|
|
|
|
|
{
|
2021-10-11 16:20:07 +05:00
|
|
|
|
b.Navigation("DrillParamsCollection");
|
|
|
|
|
|
2021-10-12 10:39:42 +05:00
|
|
|
|
b.Navigation("WellComposites");
|
|
|
|
|
|
2021-09-07 14:04:30 +05:00
|
|
|
|
b.Navigation("WellOperations");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("AsbCloudDb.Model.WellType", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Navigation("Wells");
|
|
|
|
|
});
|
|
|
|
|
#pragma warning restore 612, 618
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|