2021-06-24 13:02:31 +05:00
|
|
|
|
using Microsoft.EntityFrameworkCore;
|
|
|
|
|
using System.ComponentModel.DataAnnotations;
|
|
|
|
|
using System.ComponentModel.DataAnnotations.Schema;
|
2022-12-03 00:48:40 +05:00
|
|
|
|
using System.Text.Json.Serialization;
|
2021-06-24 13:02:31 +05:00
|
|
|
|
|
|
|
|
|
namespace AsbCloudDb.Model
|
|
|
|
|
{
|
2021-08-18 15:38:33 +05:00
|
|
|
|
[Table("t_well_operation_category"), Comment("Справочник операций на скважине")]
|
2021-09-09 12:31:12 +05:00
|
|
|
|
public class WellOperationCategory : IId
|
2021-06-24 13:02:31 +05:00
|
|
|
|
{
|
2022-12-09 18:32:18 +05:00
|
|
|
|
#region constants category operations ids
|
2022-12-09 14:36:45 +05:00
|
|
|
|
/// <summary>
|
2022-12-09 18:32:18 +05:00
|
|
|
|
/// БУРЕНИЕ
|
2022-12-09 14:36:45 +05:00
|
|
|
|
/// </summary>
|
2022-12-09 18:32:18 +05:00
|
|
|
|
public const int IdDrilling = 3000;
|
2022-12-09 14:36:45 +05:00
|
|
|
|
/// <summary>
|
2022-12-09 18:32:18 +05:00
|
|
|
|
/// Непроизводительное время (НПВ)
|
2022-12-09 14:36:45 +05:00
|
|
|
|
/// </summary>
|
2022-12-09 18:32:18 +05:00
|
|
|
|
public const int IdNonProductiveTime = 3005;
|
|
|
|
|
|
2022-12-09 14:36:45 +05:00
|
|
|
|
/// <summary>
|
2022-12-09 18:32:18 +05:00
|
|
|
|
/// Механическое. бурение
|
2022-12-09 14:36:45 +05:00
|
|
|
|
/// </summary>
|
2022-12-09 18:32:18 +05:00
|
|
|
|
public const int IdMechanicalDrilling = 4001;
|
|
|
|
|
|
2022-12-09 14:36:45 +05:00
|
|
|
|
/// <summary>
|
2022-12-09 18:32:18 +05:00
|
|
|
|
/// Разборка КНБК
|
2022-12-09 14:36:45 +05:00
|
|
|
|
/// </summary>
|
2022-12-09 18:32:18 +05:00
|
|
|
|
public const int IdBhaDisassembly = 5000;
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// Сборка КНБК
|
|
|
|
|
/// </summary>
|
|
|
|
|
public const int IdBhaAssembly = 5001;
|
2022-12-09 14:36:45 +05:00
|
|
|
|
/// <summary>
|
2023-03-01 12:08:34 +05:00
|
|
|
|
/// Бурение слайдом
|
2022-12-09 14:36:45 +05:00
|
|
|
|
/// </summary>
|
|
|
|
|
public const int IdSlide = 5002;
|
|
|
|
|
/// <summary>
|
2023-03-01 12:08:34 +05:00
|
|
|
|
/// Бурение ротором
|
2022-12-09 14:36:45 +05:00
|
|
|
|
/// </summary>
|
2022-12-09 18:32:18 +05:00
|
|
|
|
public const int IdRotor = 5003;
|
2022-12-09 14:36:45 +05:00
|
|
|
|
/// <summary>
|
|
|
|
|
/// Замер ЗТС (запись MWD)
|
|
|
|
|
/// </summary>
|
|
|
|
|
public const int IdStaticSurveying = 5004;
|
|
|
|
|
/// <summary>
|
2022-12-09 18:32:18 +05:00
|
|
|
|
/// Промывка перед наращиванием
|
2022-12-09 14:36:45 +05:00
|
|
|
|
/// </summary>
|
2022-12-09 18:32:18 +05:00
|
|
|
|
public const int IdFlashingBeforeConnection = 5005;
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// Проработка перед наращиванием
|
|
|
|
|
/// </summary>
|
|
|
|
|
public const int IdDevelopment = 5007;
|
2022-12-09 14:36:45 +05:00
|
|
|
|
/// <summary>
|
|
|
|
|
/// Шаблонировка во время бурения
|
|
|
|
|
/// </summary>
|
|
|
|
|
public const int IdTemplatingWhileDrilling = 5008;
|
|
|
|
|
/// <summary>
|
2022-12-09 18:32:18 +05:00
|
|
|
|
/// Шаблонировка перед наращиванием
|
2022-12-09 14:36:45 +05:00
|
|
|
|
/// </summary>
|
2022-12-09 18:32:18 +05:00
|
|
|
|
public const int IdTemplating = 5009;
|
2022-12-09 14:36:45 +05:00
|
|
|
|
/// <summary>
|
2022-12-09 18:32:18 +05:00
|
|
|
|
/// Удержание в клиньях
|
2022-12-09 14:36:45 +05:00
|
|
|
|
/// </summary>
|
2022-12-09 18:32:18 +05:00
|
|
|
|
public const int IdSlipsTime = 5011;
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// Подъем КНБК
|
|
|
|
|
/// </summary>
|
|
|
|
|
public const int IdBhaUp = 5013;
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// Спуск КНБК
|
|
|
|
|
/// </summary>
|
|
|
|
|
public const int IdBhaDown = 5015;
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// Спуск ОК
|
|
|
|
|
/// </summary>
|
|
|
|
|
public const int IdCasingDown = 5017;
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// Промывка
|
|
|
|
|
/// </summary>
|
|
|
|
|
public const int IdFlashing = 5036;
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// Ремонт бурового оборудования
|
|
|
|
|
/// </summary>
|
|
|
|
|
public const int IdEquipmentRepair = 5058;
|
2023-03-27 17:14:36 +05:00
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// КНБК
|
|
|
|
|
/// </summary>
|
|
|
|
|
public const int Knbk = 4000;
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// СПО
|
|
|
|
|
/// </summary>
|
|
|
|
|
public const int SPO = 4005;
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// ГИС
|
|
|
|
|
/// </summary>
|
|
|
|
|
public const int GIS = 4011;
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// Статический замер
|
|
|
|
|
/// </summary>
|
|
|
|
|
public const int MeasurementStat = 4002;
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// Нормализация диаметра скважины
|
|
|
|
|
/// </summary>
|
|
|
|
|
public const int NormalizedWellDiameter = 4003;
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// Наращивание
|
|
|
|
|
/// </summary>
|
|
|
|
|
public const int Building = 4004;
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// Спуск обсадной колонны
|
|
|
|
|
/// </summary>
|
|
|
|
|
public const int CasingRunning = 4006;
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// Цементирование
|
|
|
|
|
/// </summary>
|
|
|
|
|
public const int Cementing = 4007;
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// Вспомогательные работы при креплении
|
|
|
|
|
/// </summary>
|
|
|
|
|
public const int AuxiliaryWorkFastening = 4008;
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// Сборка/разборка приборов ГИС
|
|
|
|
|
/// </summary>
|
|
|
|
|
public const int AssemblyOrDisassemblyGIS = 4009;
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// СПО2
|
|
|
|
|
/// </summary>
|
|
|
|
|
public const int SPO2 = 4010;
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// Промывка, ОБР
|
|
|
|
|
/// </summary>
|
|
|
|
|
public const int FlushingOBR = 4012;
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// Вспомогательные работы
|
|
|
|
|
/// </summary>
|
|
|
|
|
public const int AuxiliaryWork = 4013;
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// Ремонт оборудования
|
|
|
|
|
/// </summary>
|
|
|
|
|
public const int EquipmentRepair = 4014;
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// Аварийные работы
|
|
|
|
|
/// </summary>
|
|
|
|
|
public const int EmergencyWork = 4015;
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// Осложнение
|
|
|
|
|
/// </summary>
|
|
|
|
|
public const int Complication = 4016;
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// Незаложенные в ГГД операции
|
|
|
|
|
/// </summary>
|
|
|
|
|
public const int OperationsNotIncludedGGD = 4017;
|
|
|
|
|
|
2022-12-09 18:32:18 +05:00
|
|
|
|
/// <summary>
|
|
|
|
|
/// Список всех категорий НПВ
|
|
|
|
|
/// </summary>
|
|
|
|
|
public static readonly int[] NonProductiveTimeSubIds = {
|
|
|
|
|
IdEquipmentRepair,
|
|
|
|
|
5059,
|
|
|
|
|
5060,
|
|
|
|
|
5061,
|
|
|
|
|
5062,
|
|
|
|
|
5063,
|
|
|
|
|
5064,
|
|
|
|
|
5065,
|
|
|
|
|
5066,
|
|
|
|
|
5067,
|
|
|
|
|
5068,
|
|
|
|
|
5069,
|
|
|
|
|
5070,
|
|
|
|
|
5071,
|
|
|
|
|
5072,
|
|
|
|
|
5073,
|
|
|
|
|
5074,
|
|
|
|
|
5075,
|
|
|
|
|
5076,
|
|
|
|
|
5077,
|
|
|
|
|
5078,
|
|
|
|
|
5079,
|
2023-03-01 11:39:47 +05:00
|
|
|
|
5101,
|
2022-12-09 18:32:18 +05:00
|
|
|
|
|
|
|
|
|
4014,
|
|
|
|
|
4015,
|
|
|
|
|
4016,
|
|
|
|
|
4017,
|
|
|
|
|
|
|
|
|
|
IdNonProductiveTime,
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
public static readonly int[] MechanicalDrillingSubIds = { IdRotor, IdSlide, IdMechanicalDrilling, };
|
2022-12-09 14:36:45 +05:00
|
|
|
|
#endregion
|
|
|
|
|
|
2021-06-24 13:02:31 +05:00
|
|
|
|
[Key]
|
|
|
|
|
[Column("id")]
|
|
|
|
|
public int Id { get; set; }
|
2021-08-13 14:50:13 +05:00
|
|
|
|
|
2021-08-16 14:19:43 +05:00
|
|
|
|
[Column("name"), Comment("Название категории операции")]
|
2022-12-09 18:32:18 +05:00
|
|
|
|
public string Name { get; set; } = null!;
|
2021-06-24 13:02:31 +05:00
|
|
|
|
|
2022-12-03 00:48:40 +05:00
|
|
|
|
[Column("id_parent"), Comment("id родительской категории")]
|
|
|
|
|
public int? IdParent { get; set; }
|
2021-08-13 15:35:03 +05:00
|
|
|
|
|
2022-08-08 16:45:20 +05:00
|
|
|
|
[Column("key_value_name"), Comment("Название ключевого показателя операции"), StringLength(32)]
|
2022-12-09 18:32:18 +05:00
|
|
|
|
public string? KeyValueName { get; set; }
|
2022-08-08 16:45:20 +05:00
|
|
|
|
|
|
|
|
|
[Column("key_value_units"), Comment("Единицы измерения ключевого показателя операции"), StringLength(16)]
|
2022-12-09 18:32:18 +05:00
|
|
|
|
public string? KeyValueUnits { get; set; }
|
2022-12-03 00:48:40 +05:00
|
|
|
|
|
|
|
|
|
[JsonIgnore]
|
|
|
|
|
[ForeignKey(nameof(IdParent))]
|
2022-12-09 18:32:18 +05:00
|
|
|
|
public virtual WellOperationCategory? Parent { get; set; } = null!;
|
2021-06-24 13:02:31 +05:00
|
|
|
|
}
|
|
|
|
|
}
|