You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

187 lines
6.0 KiB

3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
  1. using System;
  2. using System.Collections.Generic;
  3. using System.ComponentModel.DataAnnotations;
  4. using System.ComponentModel.DataAnnotations.Schema;
  5. using Microsoft.EntityFrameworkCore;
  6. using Volo.Abp.Auditing;
  7. using Volo.Abp.Domain.Entities;
  8. using Volo.Abp.Domain.Entities.Auditing;
  9. namespace Shentun.Peis.Models
  10. {
  11. /// <summary>
  12. /// 组合项目
  13. /// </summary>
  14. [Table("asbitem")]
  15. [Index(nameof(DisplayName), Name = "ix_asbitem", IsUnique = true)]
  16. public class Asbitem : AuditedEntity<Guid>
  17. {
  18. public Asbitem()
  19. {
  20. AsbitemDetails = new HashSet<AsbitemDetail>();
  21. ChargeAsbitems = new HashSet<ChargeAsbitem>();
  22. CustomerOrgGroupDetails = new HashSet<CustomerOrgGroupDetail>();
  23. MedicalPackageDetails = new HashSet<MedicalPackageDetail>();
  24. RegisterAsbitems = new HashSet<RegisterAsbitem>();
  25. Rooms = new HashSet<Room>();
  26. }
  27. /// <summary>
  28. /// 名称
  29. /// </summary>
  30. [Column("display_name")]
  31. [StringLength(30)]
  32. public string DisplayName { get; set; } = null!;
  33. /// <summary>
  34. /// 简称
  35. /// </summary>
  36. [Column("short_name")]
  37. [StringLength(20)]
  38. public string? ShortName { get; set; }
  39. /// <summary>
  40. /// 适用性别,M-男,F-女,A-全部
  41. /// </summary>
  42. [Column("for_sex_id")]
  43. [MaxLength(1)]
  44. public char ForSexId { get; set; }
  45. /// <summary>
  46. /// 项目类别
  47. /// </summary>
  48. [Column("item_type_id")]
  49. public Guid ItemTypeId { get; set; }
  50. /// <summary>
  51. /// 价格
  52. /// </summary>
  53. [Column("price")]
  54. [Precision(8, 2)]
  55. public decimal Price { get; set; }
  56. /// <summary>
  57. /// 仪器类别
  58. /// </summary>
  59. [Column("device_type_id")]
  60. public Guid DeviceTypeId { get; set; }
  61. /// <summary>
  62. /// 发票类别
  63. /// </summary>
  64. [Column("invoice_item_type_id")]
  65. public Guid InvoiceItemTypeId { get; set; }
  66. /// <summary>
  67. /// 项目结果合并
  68. /// </summary>
  69. [Column("is_item_result_merger")]
  70. [MaxLength(1)]
  71. public char IsItemResultMerger { get; set; }
  72. /// <summary>
  73. /// 餐前项目
  74. /// </summary>
  75. [Column("is_before_eat")]
  76. [MaxLength(1)]
  77. public char IsBeforeEat { get; set; }
  78. /// <summary>
  79. /// 临床意义
  80. /// </summary>
  81. [Column("clinical_meaning")]
  82. [StringLength(100)]
  83. public string? ClinicalMeaning { get; set; }
  84. /// <summary>
  85. /// 默认结果
  86. /// </summary>
  87. [Column("default_result")]
  88. [StringLength(100)]
  89. public string? DefaultResult { get; set; }
  90. /// <summary>
  91. /// 候诊时间
  92. /// </summary>
  93. [Column("queue_time")]
  94. [Precision(3, 1)]
  95. public decimal QueueTime { get; set; }
  96. /// <summary>
  97. /// 启用诊断函数
  98. /// </summary>
  99. [Column("is_diagnosis_function")]
  100. [MaxLength(1)]
  101. public char IsDiagnosisFunction { get; set; }
  102. /// <summary>
  103. /// 诊断函数
  104. /// </summary>
  105. [Column("diagnosis_function")]
  106. [MaxLength(1)]
  107. public char? DiagnosisFunction { get; set; }
  108. /// <summary>
  109. /// 诊断函数处理完毕后继续处理
  110. /// </summary>
  111. [Column("is_continue_process")]
  112. [MaxLength(1)]
  113. public char IsContinueProcess { get; set; }
  114. /// <summary>
  115. /// 体检报告图片旋转90°
  116. /// </summary>
  117. [Column("is_picture_rotate")]
  118. [MaxLength(1)]
  119. public char IsPictureRotate { get; set; }
  120. /// <summary>
  121. /// 是检查项目
  122. /// </summary>
  123. [Column("is_check")]
  124. [MaxLength(1)]
  125. public char IsCheck { get; set; }
  126. /// <summary>
  127. /// 是启用
  128. /// </summary>
  129. [Column("is_active")]
  130. [MaxLength(1)]
  131. public char IsActive { get; set; }
  132. [Column("simple_code")]
  133. [StringLength(30)]
  134. public string SimpleCode { get; set; } = null!;
  135. [Column("display_order")]
  136. public int DisplayOrder { get; set; }
  137. [ForeignKey(nameof(InvoiceItemTypeId))]
  138. [InverseProperty("Asbitems")]
  139. public virtual InvoiceItemType InvoiceItemType { get; set; } = null!;
  140. [ForeignKey(nameof(ItemTypeId))]
  141. [InverseProperty("Asbitems")]
  142. public virtual ItemType ItemType { get; set; } = null!;
  143. [InverseProperty("Asbitem")]
  144. public virtual SampleGroupDetail SampleGroupDetail { get; set; } = null!;
  145. [InverseProperty(nameof(AsbitemDetail.Asbitem))]
  146. public virtual ICollection<AsbitemDetail> AsbitemDetails { get; set; }
  147. [InverseProperty(nameof(ChargeAsbitem.Asbitem))]
  148. public virtual ICollection<ChargeAsbitem> ChargeAsbitems { get; set; }
  149. [InverseProperty(nameof(CustomerOrgGroupDetail.Asbitem))]
  150. public virtual ICollection<CustomerOrgGroupDetail> CustomerOrgGroupDetails { get; set; }
  151. [InverseProperty(nameof(MedicalPackageDetail.Asbitem))]
  152. public virtual ICollection<MedicalPackageDetail> MedicalPackageDetails { get; set; }
  153. [InverseProperty(nameof(RegisterAsbitem.Asbitem))]
  154. public virtual ICollection<RegisterAsbitem> RegisterAsbitems { get; set; }
  155. [ForeignKey("AsbitemId")]
  156. [InverseProperty(nameof(Room.Asbitems))]
  157. public virtual ICollection<Room> Rooms { get; set; }
  158. #region 审计属性
  159. //public DateTime CreationTime { get; set; }
  160. //public Guid? CreatorId { get; set; }
  161. //public Guid? LastModifierId { get; set; }
  162. //public DateTime? LastModificationTime { get; set; }
  163. //public Guid? DeleterId { get; set; }
  164. //public DateTime? DeletionTime { get; set; }
  165. //public bool IsDeleted { get; set; }
  166. //public override object[] GetKeys()
  167. //{
  168. // return new object[] { AsbitemId };
  169. //}
  170. #endregion
  171. }
  172. }