优化数据库表
continuous-integration/drone/push Build is passing Details

IRC_NewDev
hang 2024-09-19 16:40:17 +08:00
parent 4e7ce826c8
commit b98df9dae8
23 changed files with 876 additions and 971 deletions

View File

@ -295,9 +295,9 @@ namespace IRaCIS.Api.Controllers
[HttpGet, Route("user/getPublicKey")] [HttpGet, Route("user/getPublicKey")]
public IResponseOutput GetPublicKey([FromServices] IOptionsMonitor<IRCEncreptOption> _IRCEncreptOption) public IResponseOutput GetPublicKey([FromServices] IOptionsMonitor<IRCEncreptOption> _IRCEncreptOption)
{ {
var pemPublicKey = Encoding.UTF8.GetString(Convert.FromBase64String(_IRCEncreptOption.CurrentValue.Base64RSAPublicKey)); //var pemPublicKey = Encoding.UTF8.GetString(Convert.FromBase64String(_IRCEncreptOption.CurrentValue.Base64RSAPublicKey));
return ResponseOutput.Ok(pemPublicKey); return ResponseOutput.Ok(_IRCEncreptOption.CurrentValue.Base64RSAPublicKey);
} }

View File

@ -253,7 +253,7 @@ namespace IRaCIS.Application.Services
public string Code { get; set; } public string Code { get; set; }
} }
public IResponseOutput TestEncreptTest(TestEncrept testModel) public IResponseOutput TestEncreptTest(TestEncrept testModel)
{ {
return ResponseOutput.Ok(testModel); return ResponseOutput.Ok(testModel);
} }
@ -276,6 +276,12 @@ namespace IRaCIS.Application.Services
{ {
var _IRCEncreptOption = _encreptResponseMonitor.CurrentValue; var _IRCEncreptOption = _encreptResponseMonitor.CurrentValue;
var publicKey = Encoding.UTF8.GetString(Convert.FromBase64String(_IRCEncreptOption.Base64RSAPublicKey));
var privateKey = Encoding.UTF8.GetString(Convert.FromBase64String(_IRCEncreptOption.Base64RSAPrivateKey));
Console.WriteLine(RSAEncryption.Encrypt(publicKey, MD5Helper.Md5("123456")));
string plainText = "Hello, BouncyCastle!"; string plainText = "Hello, BouncyCastle!";
string key = "12345678901234567890123456789012"; // AES 密钥长度应为 16 字节128 位) string key = "12345678901234567890123456789012"; // AES 密钥长度应为 16 字节128 位)
string iv = "your-iv-12345678"; // IV 长度为 16 字节 string iv = "your-iv-12345678"; // IV 长度为 16 字节
@ -320,13 +326,12 @@ namespace IRaCIS.Application.Services
var publicKey = Encoding.UTF8.GetString(Convert.FromBase64String(_IRCEncreptOption.Base64RSAPublicKey));
var privateKey = Encoding.UTF8.GetString(Convert.FromBase64String(_IRCEncreptOption.Base64RSAPrivateKey));
Console.WriteLine("Public Key:"); Console.WriteLine("Public Key:");
Console.WriteLine(privateKey);
Console.WriteLine("\nPrivate Key:");
Console.WriteLine(publicKey); Console.WriteLine(publicKey);
Console.WriteLine("\nPrivate Key:");
Console.WriteLine(privateKey);
Console.WriteLine("encrept sys Key:"); Console.WriteLine("encrept sys Key:");
Console.WriteLine($"\n{RSAEncryption.Encrypt(publicKey, key)}"); Console.WriteLine($"\n{RSAEncryption.Encrypt(publicKey, key)}");

View File

@ -1,61 +0,0 @@
//--------------------------------------------------------------------
// 此代码由T4模板自动生成 byzhouhang 20210918
// 生成时间 2022-06-07 14:09:29
// 对此文件的更改可能会导致不正确的行为,并且如果重新生成代码,这些更改将会丢失。
using System;
using IRaCIS.Core.Domain.Share;
using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;
using System.Collections.Generic;
namespace IRaCIS.Core.Domain.Models
{
///<summary>
///是否需要拆表
///</summary>
[Table("SubjectTaskCategory")]
public class SubjectTaskCategory : BaseAddAuditEntity
{
#region 导航属性
[JsonIgnore]
[ForeignKey("SouceReadModuleId")]
public ReadModule ReadModule { get; set; }
[JsonIgnore]
[ForeignKey("SourceSubjectVisitId")]
public SubjectVisit SubjectVisit { get; set; }
[JsonIgnore]
public Subject Subject { get; set; }
#endregion
public Guid TrialId { get; set; }
public string TaskName { get; set; } = string.Empty;
public string TaskBlindName { get; set; } = string.Empty;
//任务来源访视Id 方便回更访视读片状态
public Guid? SourceSubjectVisitId { get; set; }
public Guid? SouceReadModuleId { get; set; }
public ReadingCategory ReadingCategory { get; set; }
public Guid SubjectId { get; set; }
}
}

View File

@ -7,32 +7,32 @@ using System;
using IRaCIS.Core.Domain.Share; using IRaCIS.Core.Domain.Share;
using System.ComponentModel.DataAnnotations; using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema; using System.ComponentModel.DataAnnotations.Schema;
namespace IRaCIS.Core.Domain.Models using Microsoft.EntityFrameworkCore;
namespace IRaCIS.Core.Domain.Models;
[Comment("数据上传 | 数据导出 | 邮件附件 文件记录表 (需要同步)")]
[Table("CommonDocument")]
public class CommonDocument : BaseFullDeleteAuditEntity
{ {
///<summary> [Comment(" 业务场景")]
///CommonDocument public EmailBusinessScenario BusinessScenarioEnum { get; set; }
///</summary>
[Table("CommonDocument")]
public class CommonDocument : BaseFullDeleteAuditEntity
{
public string Code { get; set; } = String.Empty; public string Code { get; set; } = null!;
[Comment(" 系统标准枚举")]
public CriterionType? CriterionTypeEnum { get; set; }
public string Name { get; set; } = String.Empty; public string Description { get; set; } = null!;
public string NameCN { get; set; } = string.Empty; [Comment(" 类型-上传|导出|邮件附件")]
public CommonDocumentFileType FileTypeEnum { get; set; }
public string Path { get; set; } = String.Empty; public string Name { get; set; } = null!;
public string NameCN { get; set; } = null!;
public string Description { get; set; } = String.Empty; public string Path { get; set; } = null!;
public CriterionType? CriterionTypeEnum { get; set; }
public CommonDocumentFileType FileTypeEnum { get; set; }
public EmailBusinessScenario BusinessScenarioEnum { get; set; }
}
} }

View File

@ -1,60 +1,63 @@
using IRaCIS.Core.Domain.Share; using IRaCIS.Core.Domain.Share;
using Microsoft.EntityFrameworkCore;
using System; using System;
using System.Collections.Generic; using System.Collections.Generic;
using System.ComponentModel.DataAnnotations; using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema; using System.ComponentModel.DataAnnotations.Schema;
namespace IRaCIS.Core.Domain.Models namespace IRaCIS.Core.Domain.Models;
[Comment("后台 - 字典表(需要同步)")]
[Table("Dictionary")]
public partial class Dictionary : BaseFullAuditEntity
{ {
[Table("Dictionary")] #region 导航属性
public partial class Dictionary : BaseFullAuditEntity [JsonIgnore]
{ public List<DoctorDictionary> DoctorDicRelationList { get; set; } = new List<DoctorDictionary>();
#region µ¼º½ÊôÐÔ
[JsonIgnore]
public List<DoctorDictionary> DoctorDicRelationList { get; set; } = new List<DoctorDictionary>();
[JsonIgnore] [JsonIgnore]
[ForeignKey("ConfigTypeId")] [ForeignKey("ConfigTypeId")]
public Dictionary ConfigDictionary { get; set; } public Dictionary ConfigDictionary { get; set; }
[JsonIgnore] [JsonIgnore]
[ForeignKey("ParentId")] [ForeignKey("ParentId")]
public Dictionary Parent { get; set; } public Dictionary Parent { get; set; }
[JsonIgnore] [JsonIgnore]
public List<Dictionary> ChildList { get; set; } = new List<Dictionary>(); public List<Dictionary> ChildList { get; set; } = new List<Dictionary>();
#endregion #endregion
public string ChildGroup { get; set; } = string.Empty; [StringLength(400)]
public string ChildGroup { get; set; } = null!;
public string Code { get; set; } = null!;
public DicDataTypeEnum DataTypeEnum { get; set; } public Guid? ConfigTypeId { get; set; }
[Comment(" 字典类型- 枚举|bool|下拉框")]
public DicDataTypeEnum DataTypeEnum { get; set; }
[Column("Value")] [StringLength(512)]
public string Value { get; set; } = string.Empty; public string Description { get; set; } = null!;
[Column("ValueCN")] [Comment(" 是否字典类型配置")]
public string ValueCN { get; set; } = string.Empty; public bool IsConfig { get; set; }
public bool IsEnable { get; set; }
[StringLength(512)] public Guid? ParentId { get; set; }
public string Description { get; set; } = string.Empty;
public int ShowOrder { get; set; } public int ShowOrder { get; set; }
public string Code { get; set; } = string.Empty; [StringLength(400)]
public string Value { get; set; } = null!;
public Guid? ParentId { get; set; } [StringLength(400)]
public string ValueCN { get; set; } = null!;
public bool IsEnable { get; set; }
public Guid? ConfigTypeId { get; set; }
}
} }

View File

@ -9,215 +9,213 @@ using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema; using System.ComponentModel.DataAnnotations.Schema;
using System.Collections.Generic; using System.Collections.Generic;
namespace IRaCIS.Core.Domain.Models namespace IRaCIS.Core.Domain.Models;
///<summary>
///FrontAuditConfig
///</summary>
[Table("FrontAuditConfig")]
public class FrontAuditConfig : BaseFullAuditEntity
{ {
///<summary> #region 导航属性
///FrontAuditConfig
///</summary>
[Table("FrontAuditConfig")]
public class FrontAuditConfig : BaseFullAuditEntity
{
#region 导航属性
#endregion #endregion
public string Value { get; set; } = String.Empty; public string Value { get; set; } = String.Empty;
public string ValueCN { get; set; } = String.Empty; public string ValueCN { get; set; } = String.Empty;
public string Description { get; set; } = String.Empty; public string Description { get; set; } = String.Empty;
public string DescriptionCN { get; set; } = String.Empty; public string DescriptionCN { get; set; } = String.Empty;
/// <summary> /// <summary>
/// 是否有签名 /// 是否有签名
/// </summary> /// </summary>
public bool IsHaveSign { get; set; } public bool IsHaveSign { get; set; }
/// <summary> /// <summary>
/// 是否有原因 /// 是否有原因
/// </summary> /// </summary>
public bool IsHaveReason { get; set; } public bool IsHaveReason { get; set; }
/// <summary> /// <summary>
/// 是否完成 /// 是否完成
/// </summary> /// </summary>
public bool IsFinish { get; set; } public bool IsFinish { get; set; }
/// <summary> /// <summary>
/// 是否加入计划 /// 是否加入计划
/// </summary> /// </summary>
public bool IsJoinPlan { get; set; } public bool IsJoinPlan { get; set; }
/// <summary> /// <summary>
/// 标识 /// 标识
/// </summary> /// </summary>
public string Identification { get; set; } = string.Empty; public string Identification { get; set; } = string.Empty;
public Guid? ParentId { get; set; } public Guid? ParentId { get; set; }
public bool IsEnable { get; set; } public bool IsEnable { get; set; }
public int Sort { get; set; } public int Sort { get; set; }
public Guid? ModuleTypeId { get; set; } public Guid? ModuleTypeId { get; set; }
public Guid? ObjectTypeId { get; set; } public Guid? ObjectTypeId { get; set; }
public Guid? OptTypeId { get; set; } public Guid? OptTypeId { get; set; }
public Guid? ChildrenTypeId { get; set; } public Guid? ChildrenTypeId { get; set; }
public int IsShowParent { get; set; } public int IsShowParent { get; set; }
public string InterfaceName { get; set; } = String.Empty; public string InterfaceName { get; set; } = String.Empty;
//前端使用 C M //前端使用 C M
public string ConfigType { get; set; } = String.Empty; public string ConfigType { get; set; } = String.Empty;
//翻译的字段名 这里有可能是一个数组名 那么具体的翻译字段名就不是这个了 //翻译的字段名 这里有可能是一个数组名 那么具体的翻译字段名就不是这个了
public string Code { get; set; } = String.Empty; public string Code { get; set; } = String.Empty;
/// <summary> /// <summary>
/// 字段的英文值 /// 字段的英文值
/// </summary> /// </summary>
public string CodeEn { get; set; } = string.Empty; public string CodeEn { get; set; } = string.Empty;
//前端渲染数组 数组名 和数组值 //前端渲染数组 数组名 和数组值
public string ChildDataLabel { get; set; } = String.Empty; public string ChildDataLabel { get; set; } = String.Empty;
/// <summary> /// <summary>
/// 前端渲染数组 数组名 和数组值 英文名称 /// 前端渲染数组 数组名 和数组值 英文名称
/// </summary> /// </summary>
public string ChildDataEnLabel { get; set; } = string.Empty; public string ChildDataEnLabel { get; set; } = string.Empty;
public string ChildDataValue { get; set; } = String.Empty; public string ChildDataValue { get; set; } = String.Empty;
/// <summary> /// <summary>
/// 翻译的字典名(单个字段翻译的时候) /// 翻译的字典名(单个字段翻译的时候)
/// </summary> /// </summary>
public string DictionaryCode { get; set; } = String.Empty; public string DictionaryCode { get; set; } = String.Empty;
/// <summary> /// <summary>
/// 前端展示类型 Router ArrayTable /// 前端展示类型 Router ArrayTable
/// </summary> /// </summary>
public string DataType { get; set; } = String.Empty; public string DataType { get; set; } = String.Empty;
// 后端翻译的类型 对应前端界面 "",Dictionary,Date // 后端翻译的类型 对应前端界面 "" Dictionary Date
public string EnumType { get; set; } = String.Empty; public string EnumType { get; set; } = String.Empty;
/// <summary> /// <summary>
/// 翻译的类型 FrontAudit 的描述 可能是Id Code /// 翻译的类型 FrontAudit 的描述 可能是Id Code
/// </summary> /// </summary>
public string DictionaryType { get; set; } = String.Empty; public string DictionaryType { get; set; } = String.Empty;
/// <summary> /// <summary>
/// 后端翻译的 日期类型 /// 后端翻译的 日期类型
/// </summary> /// </summary>
public string DateType { get; set; } = String.Empty; public string DateType { get; set; } = String.Empty;
/// <summary> 字典表 </summary> /// <summary> 字典表 </summary>
public string ForeignKeyTableName { get; set; } = String.Empty; public string ForeignKeyTableName { get; set; } = String.Empty;
/// <summary> 字典Value </summary> /// <summary> 字典Value </summary>
public string ForeignKeyValue { get; set; } = String.Empty; public string ForeignKeyValue { get; set; } = String.Empty;
/// <summary> 字典 </summary> /// <summary> 字典 </summary>
public string ForeignKeyText { get; set; } = String.Empty; public string ForeignKeyText { get; set; } = String.Empty;
/// <summary> /// <summary>
/// 英文的翻译 /// 英文的翻译
/// </summary> /// </summary>
public string ForeignKeyEnText { get; set; } = string.Empty; public string ForeignKeyEnText { get; set; } = string.Empty;
public string TableConfigJsonStr { get; set; } = String.Empty; public string TableConfigJsonStr { get; set; } = String.Empty;
public string UrlConfigJsonStr { get; set; } = String.Empty; public string UrlConfigJsonStr { get; set; } = String.Empty;
#region 废弃 #region 废弃
//未知是否有用 //未知是否有用
public bool IsConfig { get; set; } public bool IsConfig { get; set; }
/// <summary> /// <summary>
/// 是否为特殊类型 /// 是否为特殊类型
/// </summary> /// </summary>
public bool IsSpecialType { get; set; } public bool IsSpecialType { get; set; }
public string DictionaryKey { get; set; } = string.Empty; public string DictionaryKey { get; set; } = string.Empty;
public bool IsShowByTrialConfig { get; set; } public bool IsShowByTrialConfig { get; set; }
public string TrialConfigRelyFieldName { get; set; } = string.Empty; public string TrialConfigRelyFieldName { get; set; } = string.Empty;
#endregion #endregion
} }
public class UrlConfig public class UrlConfig
{ {
public bool IsRoute { get; set; } public bool IsRoute { get; set; }
public string RoutePath { get; set; } = string.Empty; public string RoutePath { get; set; } = string.Empty;
public bool IsHaveParameters { get; set; } public bool IsHaveParameters { get; set; }
public List<ParameterConfig> ParameterList { get; set; } = new List<ParameterConfig>(); public List<ParameterConfig> ParameterList { get; set; } = new List<ParameterConfig>();
public class ParameterConfig public class ParameterConfig
{ {
public string UrlParameterName { get; set; } = String.Empty; public string UrlParameterName { get; set; } = String.Empty;
public string UrlParameterValueName { get; set; } = String.Empty; public string UrlParameterValueName { get; set; } = String.Empty;
} }
} }
public class TableConfig public class TableConfig
{ {
public bool IsList { get; set; } public bool IsList { get; set; }
public string ListName { get; set; } = String.Empty; public string ListName { get; set; } = String.Empty;
public bool IsFixedColumn { get; set; } public bool IsFixedColumn { get; set; }
public string FixedColumnName { get; set; } = String.Empty; public string FixedColumnName { get; set; } = String.Empty;
public string FixedColumnEnName { get; set; } = String.Empty; public string FixedColumnEnName { get; set; } = String.Empty;
public string ColumnName { get; set; } = String.Empty; public string ColumnName { get; set; } = String.Empty;
public string ColumnValue { get; set; } = String.Empty; public string ColumnValue { get; set; } = String.Empty;
public bool IsMerge { get; set; } public bool IsMerge { get; set; }
public string MergeColumnName { get; set; } = String.Empty; public string MergeColumnName { get; set; } = String.Empty;
public string MergeColumnEnName { get; set; } = String.Empty; public string MergeColumnEnName { get; set; } = String.Empty;
public string ColumnEnName { get; set; } = String.Empty; public string ColumnEnName { get; set; } = String.Empty;
public bool IsPicture { get; set; } public bool IsPicture { get; set; }
public bool IsNeedTransalate { get; set; } public bool IsNeedTransalate { get; set; }
public string TranslateDictionaryName { get; set; } = String.Empty; public string TranslateDictionaryName { get; set; } = String.Empty;
public bool IsDynamicTranslate { get; set; } public bool IsDynamicTranslate { get; set; }
}
} }

View File

@ -1,37 +1,49 @@
using Microsoft.EntityFrameworkCore;
using System; using System;
using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema; using System.ComponentModel.DataAnnotations.Schema;
namespace IRaCIS.Core.Domain.Models namespace IRaCIS.Core.Domain.Models;
//public enum AttachmentType
//{
// Avatar=1,//头像
// Resume=2,//简历
// GCP=3,//GCP证书
// MedicalLicence=4,//医师资格证
// PracticeCertificate=5,//执业资格证
// LargeEquipmentWorkingCertificate=6,//大型器械上岗证
// HighestDegreeCertificate=7//最高学历证书
//}
[Comment("医生 - 简历|证书 文档表")]
[Table("Attachment")]
public class Attachment : BaseAddAuditEntity
{ {
//public enum AttachmentType
//{
// Avatar=1,//头像
// Resume=2,//简历
// GCP=3,//GCP证书
// MedicalLicence=4,//医师资格证
// PracticeCertificate=5,//执业资格证
// LargeEquipmentWorkingCertificate=6,//大型器械上岗证
// HighestDegreeCertificate=7//最高学历证书
//}
[Table("Attachment")]
public partial class Attachment : BaseAddAuditEntity
{
[JsonIgnore] [JsonIgnore]
public Doctor Doctor { get; set; } public Doctor Doctor { get; set; }
public Guid DoctorId { get; set; } [Comment(" 编码")]
public string Type { get; set; } = string.Empty; [StringLength(400)]
public bool IsOfficial { get; set; } = false; public string Code { get; set; } = null!;
public string Path { get; set; } = string.Empty;
public string Code { get; set; } = string.Empty;
public DateTime? ExpiryDate { get; set; }
public string FileName { get; set; } = string.Empty;
//language=1 中文, 2为英文 public Guid DoctorId { get; set; }
public int Language { get; set; } = 0;
//public Guid CreateUserId { get; set; } = Guid.Empty; [Comment(" 过期时间")]
//public DateTime? CreateTime { get; set; } public DateTime? ExpiryDate { get; set; }
}
public string FileName { get; set; } = null!;
[Comment(" 是否正式简历")]
public bool IsOfficial { get; set; }
[Comment(" 1 中文 2为英文")]
public int Language { get; set; }
[StringLength(512)]
public string Path { get; set; } = null!;
[Comment(" 文件类型名")]
[StringLength(400)]
public string Type { get; set; } = null!;
} }

View File

@ -1,186 +1,194 @@
using IRaCIS.Core.Domain.Share; using IRaCIS.Core.Domain.Share;
using Microsoft.EntityFrameworkCore;
using System; using System;
using System.Collections.Generic; using System.Collections.Generic;
using System.ComponentModel.DataAnnotations; using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema; using System.ComponentModel.DataAnnotations.Schema;
namespace IRaCIS.Core.Domain.Models namespace IRaCIS.Core.Domain.Models;
[Comment("医生 - 基础信息表")]
[Table("Doctor")]
public class Doctor : BaseFullAuditEntity
{ {
[Table("Doctor")] #region 导航属性
public partial class Doctor : BaseFullAuditEntity
{
#region 导航属性
//导航属性 //导航属性
[JsonIgnore] [JsonIgnore]
public List<DoctorDictionary> DoctorDicRelationList { get; set; } = new List<DoctorDictionary>(); public List<DoctorDictionary> DoctorDicRelationList { get; set; } = new List<DoctorDictionary>();
[JsonIgnore] [JsonIgnore]
public List<TrialExperienceCriteria> TrialExperienceCriteriaList { get; set; } public List<TrialExperienceCriteria> TrialExperienceCriteriaList { get; set; }
[JsonIgnore] [JsonIgnore]
public List<Enroll> EnrollList { get; set; } public List<Enroll> EnrollList { get; set; }
[JsonIgnore] [JsonIgnore]
[ForeignKey("HospitalId")] [ForeignKey("HospitalId")]
public Hospital Hospital { get; set; } public Hospital Hospital { get; set; }
[JsonIgnore] [JsonIgnore]
[ForeignKey("SpecialityId")] [ForeignKey("SpecialityId")]
public virtual Dictionary Speciality { get; set; } public virtual Dictionary Speciality { get; set; }
[JsonIgnore] [JsonIgnore]
[ForeignKey("DepartmentId")] [ForeignKey("DepartmentId")]
public virtual Dictionary Department { get; set; } public virtual Dictionary Department { get; set; }
[JsonIgnore] [JsonIgnore]
[ForeignKey("RankId")] [ForeignKey("RankId")]
public virtual Dictionary Rank { get; set; } public virtual Dictionary Rank { get; set; }
[JsonIgnore] [JsonIgnore]
[ForeignKey("PositionId")] [ForeignKey("PositionId")]
public virtual Dictionary Position { get; set; } public virtual Dictionary Position { get; set; }
[JsonIgnore] [JsonIgnore]
public List<Attachment> AttachmentList { get; set; } public List<Attachment> AttachmentList { get; set; }
[JsonIgnore] [JsonIgnore]
public List<DoctorCriterionFile> CriterionFileList { get; set; } public List<DoctorCriterionFile> CriterionFileList { get; set; }
[JsonIgnore] [JsonIgnore]
public User User { get; set; } public User User { get; set; }
#endregion #endregion
public bool AcceptingNewTrial { get; set; }
public string ReviewerCode { get; set; } = string.Empty; public bool ActivelyReading { get; set; }
public int Code { get; set; }
[MaxLength]
public string? AdminComment { get; set; }
[StringLength(100)] public DateTime? AuditTime { get; set; }
public string Phone { get; set; } = string.Empty;
public Guid AuditUserId { get; set; }
[StringLength(100)] public string BlindName { get; set; } = null!;
public string Password { get; set; } = string.Empty;
public string BlindNameCN { get; set; } = null!;
[StringLength(50)]
public string ChineseName { get; set; } = string.Empty;
[MaxLength]
public string? BlindPublications { get; set; }
[StringLength(100)] [StringLength(400)]
public string FirstName { get; set; } = string.Empty; public string ChineseName { get; set; } = null!;
public int Code { get; set; }
[StringLength(100)] public ContractorStatusEnum CooperateStatus { get; set; } = ContractorStatusEnum.Noncooperation;
public string LastName { get; set; } = string.Empty;
[NotMapped] public Guid DepartmentId { get; set; }
public string FullName => LastName + " / " + FirstName;
public int Sex { get; set; } [StringLength(400)]
public string DepartmentOther { get; set; } = null!;
[StringLength(400)]
public string DepartmentOtherCN { get; set; } = null!;
[StringLength(100)] [StringLength(400)]
public string EMail { get; set; } = string.Empty; public string EMail { get; set; } = null!;
[StringLength(400)]
public string FirstName { get; set; } = null!;
[StringLength(100)] public int GCP { get; set; }
public string WeChat { get; set; } = string.Empty;
public Guid GCPId { get; set; }
[StringLength(1000)] public Guid HospitalId { get; set; }
public string Introduction { get; set; } = string.Empty;
public Guid? DepartmentId { get; set; } = Guid.Empty; public string HospitalOther { get; set; } = null!;
public string HospitalOtherCN { get; set; } = null!;
[StringLength(100)] [StringLength(2000)]
public string DepartmentOther { get; set; } = string.Empty; public string Introduction { get; set; } = null!;
public Guid? PhysicianId { get; set; } public bool IsVirtual { get; set; }
public string Physician { get; set; } = string.Empty;
public string PhysicianCN { get; set; } = string.Empty;
public Guid? RankId { get; set; } = Guid.Empty; public DateTime? LastLoginTime { get; set; }
[StringLength(400)]
public string LastName { get; set; } = null!;
[StringLength(100)] public int Nation { get; set; }
public string RankOther { get; set; } = string.Empty;
public Guid? PositionId { get; set; } = Guid.Empty; public Guid OrganizationId { get; set; }
[StringLength(100)] [MaxLength]
public string PositionOther { get; set; } = string.Empty; public string? OtherClinicalExperience { get; set; }
// 是否可空 意味着 左连接 否则 一直是内连接
public Guid? HospitalId { get; set; } = Guid.Empty;
[MaxLength]
public string? OtherClinicalExperienceCN { get; set; }
[StringLength(200)] [StringLength(400)]
public string HospitalOther { get; set; } = string.Empty; public string Password { get; set; } = null!;
[StringLength(100)] [StringLength(400)]
public string ReadingTypeOther { get; set; } = string.Empty; public string Phone { get; set; } = null!;
public string PhotoPath { get; set; } = null!;
[StringLength(100)] public string Physician { get; set; } = null!;
public string SubspecialityOther { get; set; } = string.Empty;
public int GCP { get; set; } public string PhysicianCN { get; set; } = null!;
public Guid? GCPId { get; set; } = Guid.Empty; public Guid? PhysicianId { get; set; }
public Guid OrganizationId { get; set; } = Guid.Empty; public Guid? PositionId { get; set; }
public string OtherClinicalExperience { get; set; } = string.Empty; [StringLength(400)]
public string OtherClinicalExperienceCN { get; set; } = string.Empty; public string PositionOther { get; set; } = null!;
public ContractorStatusEnum CooperateStatus { get; set; } = ContractorStatusEnum.Noncooperation; [StringLength(400)]
public string PositionOtherCN { get; set; } = null!;
public ResumeStatusEnum ResumeStatus { get; set; } = ResumeStatusEnum.Failed; public Guid RankId { get; set; }
[StringLength(400)]
public string RankOther { get; set; } = null!;
[StringLength(400)]
public string RankOtherCN { get; set; } = null!;
[StringLength(512)] [StringLength(400)]
public string PhotoPath { get; set; } = string.Empty; public string ReadingTypeOther { get; set; } = null!;
[StringLength(512)] [StringLength(400)]
public string ResumePath { get; set; } = string.Empty; public string ReadingTypeOtherCN { get; set; } = null!;
public Guid? SpecialityId { get; set; } = Guid.Empty;
public string SpecialityOther { get; set; } = string.Empty; [StringLength(512)]
public string ResumePath { get; set; } = null!;
public string AdminComment { get; set; } = string.Empty; public ResumeStatusEnum ResumeStatus { get; set; } = ResumeStatusEnum.Failed;
public ReviewerInformationConfirmStatus ReviewStatus { get; set; } = ReviewerInformationConfirmStatus.ConfirmRefuse; [StringLength(400)]
public string ReviewerCode { get; set; } = null!;
public bool AcceptingNewTrial { get; set; } = false; public ReviewerInformationConfirmStatus ReviewStatus { get; set; } = ReviewerInformationConfirmStatus.ConfirmRefuse;
public bool ActivelyReading { get; set; } = false;
public DateTime? LastLoginTime { get; set; } public int Sex { get; set; }
public Guid AuditUserId { get; set; } = Guid.Empty; public Guid SpecialityId { get; set; }
public DateTime? AuditTime { get; set; } [StringLength(400)]
public string SpecialityOther { get; set; } = null!;
public int Nation { get; set; } = 0; // 支付类型0-代表中国医生CN1-代表美国医生US [StringLength(400)]
public string SpecialityOtherCN { get; set; } = null!;
[StringLength(400)]
public string SubspecialityOther { get; set; } = null!;
public string ReadingTypeOtherCN { get; set; } = string.Empty; [StringLength(400)]
public string HospitalOtherCN { get; set; } = string.Empty; public string SubspecialityOtherCN { get; set; } = null!;
public string PositionOtherCN { get; set; } = string.Empty;
public string RankOtherCN { get; set; } = string.Empty;
public string DepartmentOtherCN { get; set; } = string.Empty;
public string SubspecialityOtherCN { get; set; } = string.Empty;
public string SpecialityOtherCN { get; set; } = string.Empty;
[StringLength(400)]
public string WeChat { get; set; } = null!;
public bool IsVirtual { get; set; } [NotMapped]
public string FullName => LastName + " / " + FirstName;
public string BlindName { get; set; } = string.Empty;
public string BlindNameCN { get; set; } = string.Empty;
public string BlindPublications { get; set; } = string.Empty;
}
} }

View File

@ -1,58 +1,85 @@
using System; using Microsoft.EntityFrameworkCore;
using System;
using System.ComponentModel.DataAnnotations; using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema; using System.ComponentModel.DataAnnotations.Schema;
namespace IRaCIS.Core.Domain.Models namespace IRaCIS.Core.Domain.Models;
[Comment("归档 - Instance表")]
[Table("DicomInstance")]
public class DicomInstance : BaseFullAuditEntity, IEntitySeqId
{ {
[Table("DicomInstance")] #region 导航属性
public class DicomInstance : BaseFullAuditEntity, IEntitySeqId [JsonIgnore]
{ [ForeignKey("SeriesId")]
#region 导航属性 public DicomSeries DicomSerie { get; set; }
[JsonIgnore]
[ForeignKey("SeriesId")]
public DicomSeries DicomSerie { get; set; }
[JsonIgnore] [JsonIgnore]
[ForeignKey("StudyId")] [ForeignKey("StudyId")]
public DicomStudy DicomStudy { get; set; } public DicomStudy DicomStudy { get; set; }
#endregion #endregion
public bool Anonymize { get; set; }
public bool CPIStatus { get; set; }
public long? FileSize { get; set; }
[StringLength(500)]
public string FrameOfReferenceUID { get; set; } = null!;
[StringLength(512)]
public string HtmlPath { get; set; } = null!;
public int ImageColumns { get; set; }
public int ImageRows { get; set; }
[StringLength(400)]
public string ImagerPixelSpacing { get; set; } = null!;
public int InstanceNumber { get; set; }
public DateTime? InstanceTime { get; set; }
public int NumberOfFrames { get; set; }
[MaxLength]
[Unicode(false)]
public string Path { get; set; } = null!;
public Guid SeqId { get; set; } [StringLength(400)]
public Guid StudyId { get; set; } public string PixelSpacing { get; set; } = null!;
public Guid SeriesId { get; set; }
public string StudyInstanceUid { get; set; } = String.Empty;
public string SeriesInstanceUid { get; set; } = String.Empty;
public string SopInstanceUid { get; set; } = String.Empty;
public int InstanceNumber { get; set; }
public DateTime? InstanceTime { get; set; }
public bool CPIStatus { get; set; }
public int ImageRows { get; set; }
public int ImageColumns { get; set; }
public int SliceLocation { get; set; }
public Guid SeqId { get; set; }
public string SliceThickness { get; set; } = String.Empty; public Guid SeriesId { get; set; }
public int NumberOfFrames { get; set; }
public string PixelSpacing { get; set; } = String.Empty;
public string ImagerPixelSpacing { get; set; } = String.Empty; public string SeriesInstanceUid { get; set; } = null!;
public string FrameOfReferenceUID { get; set; } = String.Empty;
public string WindowCenter { get; set; } = String.Empty;
public string WindowWidth { get; set; } = String.Empty;
public int SliceLocation { get; set; }
public Guid TrialId { get; set; } [StringLength(400)]
public string SliceThickness { get; set; } = null!;
public Guid SubjectId { get; set; } public string SopInstanceUid { get; set; } = null!;
public Guid SubjectVisitId { get; set; }
public bool Anonymize { get; set; }
public string Path { get; set; } = String.Empty;
public string HtmlPath { get; set; } = string.Empty; public Guid StudyId { get; set; }
public long? FileSize { get; set; } public string StudyInstanceUid { get; set; } = null!;
} public Guid SubjectId { get; set; }
public Guid SubjectVisitId { get; set; }
public Guid TrialId { get; set; }
[StringLength(400)]
public string WindowCenter { get; set; } = null!;
[StringLength(400)]
public string WindowWidth { get; set; } = null!;
} }

View File

@ -1,62 +1,79 @@
using System; using Microsoft.EntityFrameworkCore;
using System;
using System.Collections.Generic; using System.Collections.Generic;
using System.ComponentModel.DataAnnotations; using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema; using System.ComponentModel.DataAnnotations.Schema;
namespace IRaCIS.Core.Domain.Models namespace IRaCIS.Core.Domain.Models;
[Comment("归档 - 序列表")]
public partial class DicomSeries : BaseFullDeleteAuditEntity, IEntitySeqId
{ {
[Table("DicomSeries")] #region 导航属性
public class DicomSeries : BaseFullDeleteAuditEntity, IEntitySeqId [JsonIgnore]
{ [ForeignKey("StudyId")]
#region 导航属性 public DicomStudy DicomStudy { get; set; }
[JsonIgnore]
[ForeignKey("StudyId")]
public DicomStudy DicomStudy { get; set; }
[JsonIgnore] [JsonIgnore]
public List<DicomInstance> DicomInstanceList { get; set; } public List<DicomInstance> DicomInstanceList { get; set; }
[JsonIgnore] [JsonIgnore]
public List<SubjectCriteriaEvaluationVisitStudyFilter> SubjectCriteriaEvaluationVisitStudyFilterList { get; set; } public List<SubjectCriteriaEvaluationVisitStudyFilter> SubjectCriteriaEvaluationVisitStudyFilterList { get; set; }
#endregion #endregion
public string AcquisitionNumber { get; set; } = null!;
public string AcquisitionTime { get; set; } = null!;
public Guid SeqId { get; set; } public string BodyPartExamined { get; set; } = null!;
public Guid StudyId { get; set; }
public string StudyInstanceUid { get; set; }=string.Empty;
public string SeriesInstanceUid { get; set; } = string.Empty;
public int SeriesNumber { get; set; }
public DateTime? SeriesTime { get; set; }
public string Modality { get; set; } = string.Empty;
public string Description { get; set; } = string.Empty;
public int InstanceCount { get; set; }
public string SliceThickness { get; set; } = string.Empty;
public string ImagePositionPatient { get; set; } = string.Empty; public string BodyPartForEdit { get; set; } = null!;
public string ImageOrientationPatient { get; set; } = string.Empty;
public string BodyPartExamined { get; set; } = string.Empty;
public string SequenceName { get; set; } = string.Empty;
public string ProtocolName { get; set; } = string.Empty;
public string ImagerPixelSpacing { get; set; } = string.Empty;
public string AcquisitionTime { get; set; } = string.Empty; [StringLength(500)]
public string AcquisitionNumber { get; set; } = string.Empty; public string Description { get; set; } = null!;
public string TriggerTime { get; set; } = string.Empty;
public Guid TrialId { get; set; } public string ImageOrientationPatient { get; set; } = null!;
public Guid SubjectId { get; set; } public string ImagePositionPatient { get; set; } = null!;
public Guid SubjectVisitId { get; set; }
[StringLength(1600)]
public string ImageResizePath { get; set; } = null!;
public string BodyPartForEdit { get; set; } = string.Empty; public string ImagerPixelSpacing { get; set; } = null!;
public bool IsReading { get; set; } = true; public int InstanceCount { get; set; }
public string ImageResizePath { get; set; }=string.Empty; public bool IsReading { get; set; } = true;
public Guid? VisitTaskId { get; set; } public string Modality { get; set; } = null!;
} [StringLength(500)]
public string ProtocolName { get; set; } = null!;
public Guid SeqId { get; set; }
public string SequenceName { get; set; } = null!;
public string SeriesInstanceUid { get; set; } = null!;
public int SeriesNumber { get; set; }
public DateTime? SeriesTime { get; set; }
public string SliceThickness { get; set; } = null!;
public Guid StudyId { get; set; }
public string StudyInstanceUid { get; set; } = null!;
public Guid SubjectId { get; set; }
public Guid SubjectVisitId { get; set; }
public Guid TrialId { get; set; }
public string TriggerTime { get; set; } = null!;
public Guid? VisitTaskId { get; set; }
} }

View File

@ -1,4 +1,5 @@
using System; using Microsoft.EntityFrameworkCore;
using System;
using System.Collections.Generic; using System.Collections.Generic;
using System.ComponentModel.DataAnnotations; using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema; using System.ComponentModel.DataAnnotations.Schema;
@ -36,58 +37,75 @@ namespace IRaCIS.Core.Domain.Models
#endregion #endregion
public string AccessionNumber { get; set; } = null!;
public string AcquisitionNumber { get; set; } = null!;
public string AcquisitionTime { get; set; } = null!;
[StringLength(512)]
public string BodyPartExamined { get; set; } = null!;
public string BodyPartForEdit { get; set; } = null!;
public int Code { get; set; }
[StringLength(1000)]
public string Description { get; set; } = null!;
public int InstanceCount { get; set; }
[StringLength(400)]
public string InstitutionName { get; set; } = null!;
public bool IsDoubleReview { get; set; }
public bool IsFromPACS { get; set; }
public string Modalities { get; set; } = null!;
public string ModalityForEdit { get; set; } = null!;
public string PatientAge { get; set; } = null!;
public string PatientBirthDate { get; set; } = null!;
public string PatientId { get; set; } = null!;
public string PatientName { get; set; } = null!;
public string PatientSex { get; set; } = null!;
[Comment(" 序列Id 避免内存移动")]
public Guid SeqId { get; set; } public Guid SeqId { get; set; }
public Guid TrialId { get; set; } public int SeriesCount { get; set; }
[StringLength(400)]
public string StudyCode { get; set; } = null!;
[Comment(" DicomTag.StudyID")]
public string StudyId { get; set; } = null!;
[StringLength(500)]
public string StudyInstanceUid { get; set; } = null!;
public DateTime? StudyTime { get; set; }
public Guid SubjectId { get; set; } public Guid SubjectId { get; set; }
public Guid SubjectVisitId { get; set; } public Guid SubjectVisitId { get; set; }
public int Code { get; set; } = 0; public Guid TrialId { get; set; }
public string StudyCode { get; set; } = string.Empty; public string TriggerTime { get; set; } = null!;
public string StudyInstanceUid { get; set; } = string.Empty; [Comment(" 上传时间")]
public DateTime? StudyTime { get; set; } public DateTime? UploadedTime { get; set; }
public string Modalities { get; set; } = string.Empty;
public string Description { get; set; } = string.Empty; public string Uploader { get; set; } = null!;
public int SeriesCount { get; set; } = 0;
public int InstanceCount { get; set; } = 0;
public string InstitutionName { get; set; } = string.Empty;
public string PatientId { get; set; } = string.Empty;
public string PatientName { get; set; } = string.Empty;
public string PatientAge { get; set; } = string.Empty;
public string PatientSex { get; set; } = string.Empty;
public string StudyId { get; set; } = string.Empty;
public string AccessionNumber { get; set; } = string.Empty;
public string PatientBirthDate { get; set; } = string.Empty;
public string AcquisitionTime { get; set; } = string.Empty;
public string AcquisitionNumber { get; set; } = string.Empty;
public string TriggerTime { get; set; } = string.Empty;
public string BodyPartExamined { get; set; } = string.Empty;
public string BodyPartForEdit { get; set; } = string.Empty;
public string ModalityForEdit { get; set; } = string.Empty;
//0 未知 1 单重 2 双重
public bool IsDoubleReview { get; set; }
public bool IsFromPACS { get; set; }
} }

View File

@ -1,22 +1,30 @@
using Microsoft.EntityFrameworkCore;
using System; using System;
using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema; using System.ComponentModel.DataAnnotations.Schema;
namespace IRaCIS.Core.Domain.Models namespace IRaCIS.Core.Domain.Models;
[Comment("机构 - CRO")]
[Table("CROCompany")]
public class CRO : BaseFullAuditEntity
{ {
[Table("CROCompany")] #region 导航属性
public partial class CRO : BaseFullAuditEntity
{
#region µ¼º½ÊôÐÔ
#endregion #endregion
public string CROName { get; set; } = string.Empty;
public string CRONameCN { get; set; } = string.Empty;
public string CROCode { get; set; } = string.Empty;
public string CROCode { get; set; } = null!;
public bool IsTrialLevel { get; set; } [StringLength(1000)]
public string CROName { get; set; } = null!;
[StringLength(1000)]
public string CRONameCN { get; set; } = null!;
public Guid? TrialId { get; set; } [Comment(" 是否是项目级别")]
} public bool IsTrialLevel { get; set; }
public Guid? TrialId { get; set; }
} }

View File

@ -1,29 +1,36 @@
using IRaCIS.Core.Domain.Models; using IRaCIS.Core.Domain.Models;
using IRaCIS.Core.Domain.Share; using IRaCIS.Core.Domain.Share;
using Microsoft.EntityFrameworkCore;
using System; using System;
using System.Collections.Generic; using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;
using System.Text; using System.Text;
namespace IRaCIS.Core.Domain.Models namespace IRaCIS.Core.Domain.Models;
[Comment("一致性核查 - 对话记录表")]
[Table("CheckChallengeDialog")]
public class CheckChallengeDialog : BaseAddAuditEntity
{ {
#region 导航属性
public class CheckChallengeDialog : BaseAddAuditEntity [JsonIgnore]
{ public SubjectVisit SubjectVisit { get; set; }
#region 导航属性 #endregion
[JsonIgnore]
public SubjectVisit SubjectVisit { get; set; }
#endregion
public string TalkContent { get; set; } = string.Empty; [Comment(" CRC是否需要回复 前端使用")]
public bool? IsCRCNeedReply { get; set; }
public Guid SubjectVisitId { get; set; }
[Comment(" 核查的检查信息Json")]
[MaxLength]
public string ParamInfo { get; set; } = null!;
public UserTypeEnum UserTypeEnum { get; set; } public Guid SubjectVisitId { get; set; }
[MaxLength]
public bool? IsCRCNeedReply { get; set; } public string TalkContent { get; set; } = null!;
[Comment(" 核查过程中的操作用户类型")]
public UserTypeEnum UserTypeEnum { get; set; }
public string ParamInfo { get; set; } = string.Empty;
}
} }

View File

@ -1,91 +1,54 @@
using IRaCIS.Core.Domain.Share; using IRaCIS.Core.Domain.Share;
using Microsoft.EntityFrameworkCore;
using System; using System;
using System.Collections.Generic; using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema; using System.ComponentModel.DataAnnotations.Schema;
using System.Linq; using System.Linq;
namespace IRaCIS.Core.Domain.Models namespace IRaCIS.Core.Domain.Models;
[Comment("系统 - 临床数据配置")]
[Table("ClinicalDataSystemSet")]
public class ClinicalDataSystemSet : BaseAddAuditEntity
{ {
///<summary> #region 导航属性
/// 临床资料系统配置
///</summary>
[Table("ClinicalDataSystemSet")]
public class ClinicalDataSystemSet : BaseAddAuditEntity
{
#region 导航属性
#endregion [NotMapped]
public List<int> CriterionEnumList => CriterionEnumListStr.Split('|', StringSplitOptions.RemoveEmptyEntries).Where(t => !string.IsNullOrEmpty(t) && int.TryParse(t.Trim(), out var s)).Select(t => int.Parse(t.Trim())).ToList();
/// <summary> #endregion
/// 枚举(字典里面取的)
/// </summary>
public int ClinicalDataSetEnum { get; set; }
/// <summary> public ClinicalLevel ClinicalDataLevel { get; set; }
/// 名称
/// </summary>
public string ClinicalDataSetName { get; set; } = string.Empty;
/// <summary> [StringLength(400)]
/// 是否应用 public string ClinicalDataSetEnName { get; set; } = null!;
/// </summary>
public bool IsApply { get; set; } = false;
/// <summary>
/// 英文名称 [Comment(" 枚举(字典里面取的)")]
/// </summary> public int ClinicalDataSetEnum { get; set; }
public string ClinicalDataSetEnName { get; set; } = string.Empty;
/// <summary> public string ClinicalDataSetName { get; set; } = null!;
/// 临床级别
/// </summary>
public ClinicalLevel ClinicalDataLevel { get; set; }
/// <summary> [Comment("上传方式")]
/// 上传方式 public ClinicalUploadType ClinicalUploadType { get; set; }
/// </summary>
public ClinicalUploadType ClinicalUploadType { get; set; }
/// <summary>
/// 是否启用
/// </summary>
public bool IsEnable { get; set; }
/// <summary>
/// 上传角色
/// </summary>
public UploadRole UploadRole { get; set; }
/// <summary>
/// 模板文件名称
/// </summary>
public string FileName { get; set; } = string.Empty;
/// <summary>
/// 文件路径
/// </summary>
public string Path { get; set; } = string.Empty;
public string CriterionEnumListStr { get; set; } = String.Empty;
[NotMapped]
public List<int> CriterionEnumList => CriterionEnumListStr.Split('|', StringSplitOptions.RemoveEmptyEntries).Where(t => !string.IsNullOrEmpty(t) && int.TryParse(t.Trim(), out var s)).Select(t => int.Parse(t.Trim())).ToList();
//public List<SystemClinicalDataCriterion> SystemClinicalDataCriterionList { get; set; } = new List<SystemClinicalDataCriterion>();
}
[StringLength(512)]
public string CriterionEnumListStr { get; set; } = null!;
[StringLength(400)]
public string FileName { get; set; } = null!;
[Comment("是否应用")]
public bool IsApply { get; set; }
public bool IsEnable { get; set; }
[StringLength(4000)]
public string Path { get; set; } = null!;
public UploadRole UploadRole { get; set; }
} }

View File

@ -6,105 +6,65 @@ using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema; using System.ComponentModel.DataAnnotations.Schema;
using System.Collections.Generic; using System.Collections.Generic;
using System.Linq; using System.Linq;
using Microsoft.EntityFrameworkCore;
namespace IRaCIS.Core.Domain.Models namespace IRaCIS.Core.Domain.Models;
[Comment("项目 - 临床数据适应标准配置")]
[Table("ClinicalDataTrialSet")]
public class ClinicalDataTrialSet : BaseAddAuditEntity
{ {
///<summary> #region 导航属性
/// 临床资料项目配置
///</summary>
[Table("ClinicalDataTrialSet")]
public class ClinicalDataTrialSet : BaseAddAuditEntity
{
#region 导航属性
[JsonIgnore] [JsonIgnore]
public List<ReadingClinicalData> ReadingClinicalDataList { get; set; } public List<ReadingClinicalData> ReadingClinicalDataList { get; set; }
[JsonIgnore] [JsonIgnore]
[ForeignKey("TrialId")] [ForeignKey("TrialId")]
public Trial Trial { get; set; } public Trial Trial { get; set; }
[JsonIgnore] [JsonIgnore]
public List<TrialClinicalDataSetCriterion> TrialClinicalDataSetCriteriaList { get; set; } public List<TrialClinicalDataSetCriterion> TrialClinicalDataSetCriteriaList { get; set; }
[JsonIgnore] [JsonIgnore]
public List<TrialClinicalQuestion> TrialClinicalQuestionList { get; set; } public List<TrialClinicalQuestion> TrialClinicalQuestionList { get; set; }
[JsonIgnore] [JsonIgnore]
[ForeignKey("SystemClinicalDataSetId")] [ForeignKey("SystemClinicalDataSetId")]
public ClinicalDataSystemSet? ClinicalDataSystemSet { get; set; } public ClinicalDataSystemSet? ClinicalDataSystemSet { get; set; }
#endregion #endregion
public Guid TrialId { get; set; } [Comment("临床级别")]
public ClinicalLevel ClinicalDataLevel { get; set; }
/// <summary> [StringLength(400)]
/// 名称 public string ClinicalDataSetEnName { get; set; } = null!;
/// </summary>
public string ClinicalDataSetName { get; set; }=string.Empty;
/// <summary> public string ClinicalDataSetName { get; set; } = null!;
/// 英文名称
/// </summary>
public string ClinicalDataSetEnName { get; set; } = string.Empty;
/// <summary> [Comment("上传方式")]
/// 临床级别 public ClinicalUploadType ClinicalUploadType { get; set; }
/// </summary>
public ClinicalLevel ClinicalDataLevel { get; set; }
[StringLength(512)]
public string CriterionEnumListStr { get; set; } = null!;
/// <summary> [StringLength(400)]
/// 上传方式 public string FileName { get; set; } = null!;
/// </summary>
public ClinicalUploadType ClinicalUploadType { get; set; }
[Comment("是否应用")]
public bool IsApply { get; set; }
/// <summary> public bool IsConfirm { get; set; }
/// 系统的ClinicalDataSetId
/// </summary>
public Guid? SystemClinicalDataSetId { get; set; }
/// <summary>
/// SystemClinicalDataSetId
/// </summary>
/// <summary>
/// 是否确认
/// </summary>
public bool IsConfirm { get; set; }
/// <summary>
/// 是否应用
/// </summary>
public bool IsApply { get; set; } = false;
/// <summary>
/// 上传角色
/// </summary>
public UploadRole UploadRole { get; set; }
/// <summary>
/// 模板文件名称
/// </summary>
public string FileName { get; set; } = string.Empty;
/// <summary>
/// 文件路径
/// </summary>
public string Path { get; set; } = string.Empty;
public string CriterionEnumListStr { get; set; } = String.Empty;
public List<int> CriterionEnumList => CriterionEnumListStr.Split('|', StringSplitOptions.RemoveEmptyEntries).Where(t => !string.IsNullOrEmpty(t) && int.TryParse(t.Trim(), out var s)).Select(t => int.Parse(t.Trim())).ToList();
}
[StringLength(4000)]
public string Path { get; set; } = null!;
public Guid? SystemClinicalDataSetId { get; set; }
public Guid TrialId { get; set; }
public UploadRole UploadRole { get; set; }
public List<int> CriterionEnumList => CriterionEnumListStr.Split('|', StringSplitOptions.RemoveEmptyEntries).Where(t => !string.IsNullOrEmpty(t) && int.TryParse(t.Trim(), out var s)).Select(t => int.Parse(t.Trim())).ToList();
} }

View File

@ -7,37 +7,31 @@ using System;
using IRaCIS.Core.Domain.Share; using IRaCIS.Core.Domain.Share;
using System.ComponentModel.DataAnnotations; using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema; using System.ComponentModel.DataAnnotations.Schema;
namespace IRaCIS.Core.Domain.Models using Microsoft.EntityFrameworkCore;
namespace IRaCIS.Core.Domain.Models;
[Comment("受试者 - 临床表单表格问题行记录")]
[Table("ClinicalAnswerRowInfo")]
public class ClinicalAnswerRowInfo : BaseAddAuditEntity
{ {
///<summary> #region 导航属性
///ClinicalAnswerRowInfo
///</summary> #endregion
[Table("ClinicalAnswerRowInfo")]
public class ClinicalAnswerRowInfo : BaseAddAuditEntity
{ [Comment(" 表单Id")]
#region 导航属性 public Guid ClinicalFormId { get; set; }
[Comment(" 问题Id")]
public Guid QuestionId { get; set; }
public int RowIndex { get; set; }
[Comment(" 受试者Id")]
public Guid SubjectId { get; set; }
}
#endregion
public Guid SubjectId { get; set; }
/// <summary>
/// 表单Id
/// </summary>
public Guid ClinicalFormId { get; set; }
/// <summary>
/// 问题Id
/// </summary>
public Guid QuestionId { get; set; }
/// <summary>
/// RowIndex
/// </summary>
public int RowIndex { get; set; }
}
}

View File

@ -7,50 +7,42 @@ using System;
using IRaCIS.Core.Domain.Share; using IRaCIS.Core.Domain.Share;
using System.ComponentModel.DataAnnotations; using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema; using System.ComponentModel.DataAnnotations.Schema;
namespace IRaCIS.Core.Domain.Models using Microsoft.EntityFrameworkCore;
namespace IRaCIS.Core.Domain.Models;
[Comment("受试者 - 临床表单")]
[Table("ClinicalForm")]
public class ClinicalForm : BaseAddAuditEntity
{ {
///<summary> #region 导航属性
///ClinicalForm [JsonIgnore]
///</summary> [ForeignKey("ClinicalDataTrialSetId")]
[Table("ClinicalForm")] public ClinicalDataTrialSet ClinicalDataTrialSet { get; set; }
public class ClinicalForm : BaseAddAuditEntity
{
#region 导航属性
[JsonIgnore]
[ForeignKey("ClinicalDataTrialSetId")]
public ClinicalDataTrialSet ClinicalDataTrialSet { get; set; }
[JsonIgnore] [JsonIgnore]
[ForeignKey("SubjectId")] [ForeignKey("SubjectId")]
public Subject Subject { get; set; } public Subject Subject { get; set; }
#endregion #endregion
public Guid SubjectId { get; set; } [Comment(" 检查日期")]
public DateTime? CheckDate { get; set; }
public Guid ClinicalDataTrialSetId { get; set; }
[Comment(" 截图地址")]
[StringLength(4000)]
public string PicturePath { get; set; } = null!;
public Guid? ReadingId { get; set; }
[Comment(" 受试者Id")]
public Guid SubjectId { get; set; }
public Guid TrialId { get; set; }
public Guid? VisitId { get; set; }
}
public Guid TrialId { get; set; }
/// <summary>
/// 检查日期
/// </summary>
public DateTime? CheckDate { get; set; }
/// <summary>
/// 截图地址
/// </summary>
public string PicturePath { get; set; } = string.Empty;
public Guid ClinicalDataTrialSetId { get; set; }
/// <summary>
/// VisitId
/// </summary>
public Guid? ReadingId { get; set; }
}
}

View File

@ -7,42 +7,36 @@ using System;
using IRaCIS.Core.Domain.Share; using IRaCIS.Core.Domain.Share;
using System.ComponentModel.DataAnnotations; using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema; using System.ComponentModel.DataAnnotations.Schema;
namespace IRaCIS.Core.Domain.Models using Microsoft.EntityFrameworkCore;
namespace IRaCIS.Core.Domain.Models;
[Comment("受试者 - 临床表单问题答案")]
[Table("ClinicalQuestionAnswer")]
public class ClinicalQuestionAnswer : BaseAddAuditEntity
{ {
///<summary> #region 导航属性
///ClinicalQuestionAnswer
///</summary>
[Table("ClinicalQuestionAnswer")]
public class ClinicalQuestionAnswer : BaseAddAuditEntity
{
#region 导航属性
[JsonIgnore] [JsonIgnore]
[ForeignKey("ClinicalFormId")] [ForeignKey("ClinicalFormId")]
public ClinicalForm ClinicalForm { get; set; } public ClinicalForm ClinicalForm { get; set; }
#endregion #endregion
public Guid SubjectId { get; set; } [StringLength(4000)]
public string Answer { get; set; } = null!;
/// <summary>
/// 表单Id
/// </summary>
public Guid ClinicalFormId { get; set; }
public Guid ClinicalDataTrialSetId { get; set; }
/// <summary>
/// 问题Id
/// </summary>
public Guid QuestionId { get; set; }
public string Answer { get; set; } = string.Empty; [Comment(" 表单Id")]
public Guid ClinicalFormId { get; set; }
public Guid ClinicalDataTrialSetId { get; set; } [Comment(" 问题Id")]
public Guid QuestionId { get; set; }
[Comment(" 受试者Id")]
public Guid SubjectId { get; set; }
}
}
}

View File

@ -7,37 +7,38 @@ using System;
using IRaCIS.Core.Domain.Share; using IRaCIS.Core.Domain.Share;
using System.ComponentModel.DataAnnotations; using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema; using System.ComponentModel.DataAnnotations.Schema;
namespace IRaCIS.Core.Domain.Models using Microsoft.EntityFrameworkCore;
namespace IRaCIS.Core.Domain.Models;
[Comment("受试者 - 临床表单表格问题答案")]
[Table("ClinicalTableAnswer")]
public partial class ClinicalTableAnswer : BaseAddAuditEntity
{ {
///<summary> #region 导航属性
///ClinicalTableAnswer [JsonIgnore]
///</summary> [ForeignKey("RowId")]
[Table("ClinicalTableAnswer")] public ClinicalAnswerRowInfo ClinicalAnswerRowInfo { get; set; }
public class ClinicalTableAnswer : BaseAddAuditEntity #endregion
{
#region 导航属性
[JsonIgnore]
[ForeignKey("RowId")]
public ClinicalAnswerRowInfo ClinicalAnswerRowInfo{get; set;}
#endregion
public Guid SubjectId { get; set; } [Comment(" 答案")]
[StringLength(4000)]
public string Answer { get; set; } = null!;
public Guid ClinicalFormId { get; set; } [Comment(" 表单Id")]
public Guid ClinicalFormId { get; set; }
public Guid QuestionId { get; set; } [Comment(" 问题Id")]
public Guid QuestionId { get; set; }
public Guid RowId { get; set; } [Comment(" 答案行的Id")]
public Guid RowId { get; set; }
public string Answer { get; set; }=string.Empty; [Comment(" 受试者Id")]
public Guid SubjectId { get; set; }
public Guid TableQuestionId { get; set; } public Guid TableQuestionId { get; set; }
}
}
}

View File

@ -7,46 +7,31 @@ using System;
using IRaCIS.Core.Domain.Share; using IRaCIS.Core.Domain.Share;
using System.ComponentModel.DataAnnotations; using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema; using System.ComponentModel.DataAnnotations.Schema;
namespace IRaCIS.Core.Domain.Models using Microsoft.EntityFrameworkCore;
namespace IRaCIS.Core.Domain.Models;
[Comment("系统标准 - 病灶器官表 (需要同步)")]
[Table("CriterionNidusSystem")]
public class CriterionNidusSystem : BaseAddAuditEntity
{ {
/// <summary> #region 导航属性
/// 标准病灶中间表 [ForeignKey("CriterionId")]
/// </summary> [JsonIgnore]
[Table("CriterionNidusSystem")] public ReadingQuestionCriterionTrial TrialReadingCriterion { get; set; }
public class CriterionNidusSystem : BaseAddAuditEntity #endregion
{
#region 导航属性 public Guid CriterionId { get; set; }
[ForeignKey("CriterionId")]
[JsonIgnore] public bool IsSystemCriterion { get; set; }
public ReadingQuestionCriterionTrial TrialReadingCriterion { get; set; }
#endregion [Comment("病灶类型")]
/// <summary> public LesionType LesionType { get; set; }
/// 标准ID
/// </summary> [Comment("器官类型")]
public Guid CriterionId { get; set; } public OrganType OrganType { get; set; }
}
/// <summary>
/// 器官类型
/// </summary>
public OrganType OrganType { get; set; }
/// <summary>
/// 病灶类型
/// </summary>
public LesionType LesionType { get; set; }
/// <summary>
/// 是否是系统标准
/// </summary>
public bool IsSystemCriterion { get; set; }
}
}

View File

@ -7,28 +7,24 @@ using System;
using IRaCIS.Core.Domain.Share; using IRaCIS.Core.Domain.Share;
using System.ComponentModel.DataAnnotations; using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema; using System.ComponentModel.DataAnnotations.Schema;
namespace IRaCIS.Core.Domain.Models using Microsoft.EntityFrameworkCore;
namespace IRaCIS.Core.Domain.Models;
[Comment("项目标准 - 病灶器官表")]
[Table("CriterionNidusTrial")]
public class CriterionNidusTrial : BaseAddAuditEntity
{ {
///<summary> #region 导航属性
///CriterionNidusTrial
///</summary>
[Table("CriterionNidusTrial")]
public class CriterionNidusTrial : BaseAddAuditEntity
{
#region 导航属性
#endregion #endregion
public Guid CriterionId { get; set; } public Guid CriterionId { get; set; }
public LesionType LesionType { get; set; } public LesionType LesionType { get; set; }
/// <summary> public OrganType OrganType { get; set; }
/// 器官类型 }
/// </summary>
public OrganType OrganType { get; set; }
}
}

View File

@ -6,119 +6,95 @@ using System;
using IRaCIS.Core.Domain.Share; using IRaCIS.Core.Domain.Share;
using System.ComponentModel.DataAnnotations; using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema; using System.ComponentModel.DataAnnotations.Schema;
namespace IRaCIS.Core.Domain.Models using Microsoft.EntityFrameworkCore;
namespace IRaCIS.Core.Domain.Models;
[Comment("稽查 - 记录表")]
[Table("DataInspection")]
public class DataInspection : BaseAddAuditEntity
{ {
///<summary> #region 导航属性
///DataInspection [JsonIgnore]
///</summary> [ForeignKey("TrialReadingCriterionId")]
[Table("DataInspection")] public ReadingQuestionCriterionTrial TrialReadingCriterion { get; set; }
public class DataInspection : BaseAddAuditEntity
{
[JsonIgnore]
public VisitTask VisitTask { get; set; }
#endregion
#region 导航属性 [Comment(" 批次Id")]
[JsonIgnore] public Guid BatchId { get; set; }
[ForeignKey("TrialReadingCriterionId")]
public ReadingQuestionCriterionTrial TrialReadingCriterion { get; set; }
#endregion
[Comment(" 子类")]
public Guid? ChildrenTypeId { get; set; }
public Guid? TrialId { get; set; } [Comment(" 创建人姓名")]
public string CreateUserName { get; set; } = null!;
public Guid? TrialSiteId { get; set; } public string CreateUserRealName { get; set; } = null!;
public Guid? SubjectId { get; set; } [Comment(" 阅片医生")]
public Guid? DoctorUserId { get; set; }
[Comment(" 被稽查实体名")]
public string EntityName { get; set; } = null!;
public Guid? SubjectVisitId { get; set; } [Comment(" 要稽查对象Id")]
public Guid? GeneralId { get; set; }
public Guid? VisitTaskId { get; set; } [Comment(" 标识")]
public string Identification { get; set; } = null!;
public VisitTask VisitTask { get; set; } public string IP { get; set; } = null!;
public string IP { get; set; } = string.Empty; [Comment(" 是否是前端添加")]
public bool? IsFrontAdd { get; set; }
public string Reason { get; set; } = string.Empty; public bool? IsSign { get; set; }
public bool IsSign { get; set; } [MaxLength]
public string? JsonDetail { get; set; }
/// <summary> [Comment(" 上一条json")]
/// 签名ID [MaxLength]
/// </summary> public string? LastJsonDetail { get; set; }
public Guid? SignId { get; set; }
/// <summary> public Guid? ModuleTypeId { get; set; }
/// 父类ID
/// </summary>
public Guid? ParentId { get; set; } [Comment(" 被稽查对象外键1")]
public Guid? ObjectRelationParentId { get; set; }
/// <summary> public Guid? ObjectRelationParentId2 { get; set; }
/// 子类
/// </summary>
public Guid? ChildrenTypeId { get; set; }
/// <summary>
/// 对象类型
/// </summary>
public Guid? ObjectTypeId { get; set; }
/// <summary> public Guid? ObjectRelationParentId3 { get; set; }
/// 操作类型
/// </summary>
public Guid? OptTypeId { get; set; }
/// <summary> public Guid? ObjectTypeId { get; set; }
/// 功能模块
/// </summary>
public Guid? ModuleTypeId { get; set; }
public string JsonDetail { get; set; } = string.Empty; public Guid? OptTypeId { get; set; }
public string CreateUserName { get; set; } = string.Empty; [Comment(" 父ID")]
public Guid? ParentId { get; set; }
public string CreateUserRealName { get; set; } = string.Empty; public string Reason { get; set; } = null!;
public string RoleName { get; set; } = string.Empty; [Comment(" 角色名称")]
public string RoleName { get; set; } = null!;
/// <summary> public Guid? SignId { get; set; }
/// 标识
/// </summary>
public string Identification { get; set; } = string.Empty;
public Guid? SubjectId { get; set; }
/// <summary> public Guid? SubjectVisitId { get; set; }
/// 稽查的对象Id
/// </summary>
public Guid? GeneralId { get; set; }
public Guid? TrialId { get; set; }
public Guid? TrialReadingCriterionId { get; set; }
/// <summary> public Guid? TrialSiteId { get; set; }
/// 批次Id
/// </summary>
public Guid BatchId { get; set; }
/// <summary>
/// 稽查对象关联的父对象Id
/// </summary>
public Guid? ObjectRelationParentId { get; set; }
public Guid? ObjectRelationParentId2 { get; set; }
public Guid? ObjectRelationParentId3 { get; set; }
public string EntityName { get; set; } = string.Empty;
public Guid? TrialReadingCriterionId { get; set; }
public Guid? DoctorUserId { get; set; }
}
[Comment(" 访视计划ID")]
public Guid? VisitStageId { get; set; }
public Guid? VisitTaskId { get; set; }
} }

View File

@ -98,9 +98,11 @@ public partial class <#= EntityType.Name #>: BaseFullAuditEntity
[StringLength(<#= maxLength.Value #>)] [StringLength(<#= maxLength.Value #>)]
<# <#
} }
else if(maxLength.HasValue && maxLength == 200){}
else else
{ {
#> #>
[MaxLength] [MaxLength]
<# <#
} }