using System; using System.Collections.Generic; using System.ComponentModel.DataAnnotations; using System.ComponentModel.DataAnnotations.Schema; using Microsoft.EntityFrameworkCore; using Volo.Abp.Domain.Entities; using Volo.Abp.Domain.Entities.Auditing; namespace Shentun.Peis.Models { /// /// 标本容器设置 /// [Table("sample_container")] [Index(nameof(DisplayName), Name = "ix_sample_container", IsUnique = true)] public class SampleContainer : AuditedEntity, IDisplayName, IDisplayOrder, IHasConcurrencyStamp { public SampleContainer() { // LisRequests = new HashSet(); SampleGroups = new HashSet(); } [Column("display_name")] [StringLength(20)] public string DisplayName { get; set; } = null!; /// /// 颜色名 /// [Column("container_color_name")] [StringLength(20)] public string ContainerColorName { get; set; } = null!; /// /// 颜色 /// [Column("container_color")] public int ContainerColor { get; set; } [Column("simple_code")] [StringLength(20)] public string SimpleCode { get; set; } = null!; [Column("display_order")] public int DisplayOrder { get; set; } /// /// 备注 /// [Column("container_remark")] [StringLength(500)] public string? ContainerRemark { get; set; } [Column("concurrency_stamp")] public string ConcurrencyStamp { get; set; } //[Column("last_modifier_id")] //public Guid LastModifierId { get; set; } //[Column("last_modification_time", TypeName = "timestamp without time zone")] //public DateTime LastModificationTime { get; set; } //[Column("creator_id")] //public Guid CreatorId { get; set; } //[Column("creation_time", TypeName = "timestamp without time zone")] //public DateTime CreationTime { get; set; } //[Column("concurrency_stamp")] //[StringLength(40)] //public string ConcurrencyStamp { get; set; } = null!; [InverseProperty(nameof(LisRequest.SampleContainer))] public virtual ICollection LisRequests { get; set; } [InverseProperty(nameof(SampleGroup.SampleContainer))] public virtual ICollection SampleGroups { get; set; } //public override object[] GetKeys() //{ // return new object[] { SampleContainerId }; //} } }