2021-07-21 15:22:58 +05:00
|
|
|
|
using Microsoft.EntityFrameworkCore;
|
|
|
|
|
using System;
|
2021-07-21 12:30:51 +05:00
|
|
|
|
using System.Collections.Generic;
|
2021-04-02 17:28:07 +05:00
|
|
|
|
using System.ComponentModel.DataAnnotations;
|
|
|
|
|
using System.ComponentModel.DataAnnotations.Schema;
|
2021-08-16 10:21:46 +05:00
|
|
|
|
using System.Text.Json.Serialization;
|
2021-04-02 17:28:07 +05:00
|
|
|
|
|
|
|
|
|
#nullable disable
|
|
|
|
|
|
|
|
|
|
namespace AsbCloudDb.Model
|
|
|
|
|
{
|
|
|
|
|
[Table("t_well"), Comment("скважины")]
|
2021-07-19 15:11:01 +05:00
|
|
|
|
public partial class Well : IId, IMapPoint
|
2021-04-02 17:28:07 +05:00
|
|
|
|
{
|
|
|
|
|
[Key]
|
|
|
|
|
[Column("id")]
|
|
|
|
|
public int Id { get; set; }
|
|
|
|
|
|
|
|
|
|
[Column("caption")]
|
|
|
|
|
[StringLength(255)]
|
|
|
|
|
public string Caption { get; set; }
|
|
|
|
|
|
|
|
|
|
[Column("id_cluster")]
|
|
|
|
|
public int? IdCluster { get; set; }
|
|
|
|
|
|
|
|
|
|
[Column("id_telemetry")]
|
|
|
|
|
public int? IdTelemetry { get; set; }
|
|
|
|
|
|
2021-07-21 15:22:58 +05:00
|
|
|
|
[Column("id_well_type")]
|
|
|
|
|
public int? IdWellType { get; set; }
|
2021-07-19 15:11:01 +05:00
|
|
|
|
|
|
|
|
|
[Column("latitude")]
|
2021-07-21 15:22:58 +05:00
|
|
|
|
public double? Latitude { get; set; }
|
2021-07-19 15:11:01 +05:00
|
|
|
|
|
|
|
|
|
[Column("longitude")]
|
2021-07-21 15:22:58 +05:00
|
|
|
|
public double? Longitude { get; set; }
|
|
|
|
|
|
|
|
|
|
[ForeignKey(nameof(IdWellType))]
|
|
|
|
|
[InverseProperty(nameof(Model.WellType.Wells))]
|
|
|
|
|
public virtual WellType WellType { get; set; }
|
2021-07-21 15:29:19 +05:00
|
|
|
|
|
2021-07-21 16:30:57 +05:00
|
|
|
|
[InverseProperty(nameof(RelationCompanyWell.Well))]
|
|
|
|
|
public virtual ICollection<RelationCompanyWell> RelationCompaniesWells { get; set; }
|
2021-07-21 15:22:58 +05:00
|
|
|
|
|
|
|
|
|
[ForeignKey(nameof(IdCluster))]
|
|
|
|
|
[InverseProperty(nameof(Model.Cluster.Wells))]
|
|
|
|
|
public virtual Cluster Cluster { get; set; }
|
|
|
|
|
|
|
|
|
|
[ForeignKey(nameof(IdTelemetry))]
|
|
|
|
|
[InverseProperty(nameof(Model.Telemetry.Well))]
|
|
|
|
|
public virtual Telemetry Telemetry { get; set; }
|
2021-08-16 10:21:46 +05:00
|
|
|
|
|
|
|
|
|
[JsonIgnore]
|
|
|
|
|
[InverseProperty(nameof(WellOperation.Well))]
|
|
|
|
|
public virtual ICollection<WellOperation> WellOperations { get; set; }
|
2021-04-02 17:28:07 +05:00
|
|
|
|
}
|
|
|
|
|
}
|