From d61fba9d95e600358a1a03ba484e5045d0ca5241 Mon Sep 17 00:00:00 2001
From: hang <872297557@qq.com>
Date: Thu, 13 Feb 2025 10:17:01 +0800
Subject: [PATCH] =?UTF-8?q?Uat=20=E5=BD=B1=E5=83=8F=E9=98=85=E7=89=87?=
=?UTF-8?q?=E5=88=9D=E6=AD=A5=E4=BF=AE=E6=94=B9?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
.../IRaCIS.Core.Application.xml | 10 +
.../Service/QC/QCOperationService.cs | 118 +-
.../Service/Visit/SubjectVisitService.cs | 5 +-
IRaCIS.Core.Domain/Image/DicomInstance.cs | 4 +-
...213021502_AddInstanceIsReading.Designer.cs | 18581 ++++++++++++++++
.../20250213021502_AddInstanceIsReading.cs | 61 +
.../IRaCISDBContextModelSnapshot.cs | 12 +
7 files changed, 18763 insertions(+), 28 deletions(-)
create mode 100644 IRaCIS.Core.Infra.EFCore/Migrations/20250213021502_AddInstanceIsReading.Designer.cs
create mode 100644 IRaCIS.Core.Infra.EFCore/Migrations/20250213021502_AddInstanceIsReading.cs
diff --git a/IRaCIS.Core.Application/IRaCIS.Core.Application.xml b/IRaCIS.Core.Application/IRaCIS.Core.Application.xml
index 07e7bc1c8..909f16392 100644
--- a/IRaCIS.Core.Application/IRaCIS.Core.Application.xml
+++ b/IRaCIS.Core.Application/IRaCIS.Core.Application.xml
@@ -16621,6 +16621,16 @@
+
+
+ 1、设置为不读片,2 设置为读片(取消 先前设置为不读片) 4 设置为删除(数据库记录软删除) 5 恢复为未删除
+
+
+
+
+
+
+
type 1 :study 2: series 3:非dicom QC修改检查部位和 拍片类型
diff --git a/IRaCIS.Core.Application/Service/QC/QCOperationService.cs b/IRaCIS.Core.Application/Service/QC/QCOperationService.cs
index 37ddc5d59..bf12c9a31 100644
--- a/IRaCIS.Core.Application/Service/QC/QCOperationService.cs
+++ b/IRaCIS.Core.Application/Service/QC/QCOperationService.cs
@@ -34,7 +34,7 @@ namespace IRaCIS.Core.Application.Image.QA
IRepository _dicomInstanceRepository,
IRepository _trialQCQuestionAnswerRepository,
IRepository _readingQuestionCriterionTrialRepository,
- IDistributedLockProvider _distributedLockProvider, IReadingClinicalDataService _readingClinicalDataService,
+ IDistributedLockProvider _distributedLockProvider, IReadingClinicalDataService _readingClinicalDataService,
IMapper _mapper, IUserInfo _userInfo, IStringLocalizer _localizer, IWebHostEnvironment _hostEnvironment) : BaseService, IQCOperationService
{
@@ -43,7 +43,7 @@ namespace IRaCIS.Core.Application.Image.QA
#region QC质疑 以及回复 关闭
[HttpGet("{trialId:guid}/{subjectVisitId:guid}/{currentQCType:int}")]
- [TrialGlobalLimit( "AfterStopCannNotOpt" )]
+ [TrialGlobalLimit("AfterStopCannNotOpt")]
//[Authorize(Policy = IRaCISPolicy.IQC)]
public async Task VerifyQCCanAddChallenge(Guid subjectVisitId, [FromRoute] CurrentQC currentQCType)
{
@@ -67,7 +67,7 @@ namespace IRaCIS.Core.Application.Image.QA
///
///
[HttpPost("{trialId:guid}/{trialQCProcess:int}/{currentQCType:int}")]
- [TrialGlobalLimit( "AfterStopCannNotOpt" )]
+ [TrialGlobalLimit("AfterStopCannNotOpt")]
//[Authorize(Policy = IRaCISPolicy.IQC)]
public async Task AddOrUpdateQCChallenge(QCChallengeCommand qaQuestionCommand, Guid trialId, [FromRoute] TrialQCProcess trialQCProcess, [FromRoute] CurrentQC currentQCType)
{
@@ -126,7 +126,7 @@ namespace IRaCIS.Core.Application.Image.QA
///
///
[HttpPut]
- [TrialGlobalLimit( "AfterStopCannNotOpt" )]
+ [TrialGlobalLimit("AfterStopCannNotOpt")]
[UnitOfWork]
//[Authorize(Policy = IRaCISPolicy.IQC)]
public async Task CloseQCChallenge(CloseQCChallengeInDto input)
@@ -181,7 +181,7 @@ namespace IRaCIS.Core.Application.Image.QA
///
///
[HttpDelete("{trialId:guid}/{subjectVisitId:guid}/{qcChallengeId:guid}")]
- [TrialGlobalLimit( "AfterStopCannNotOpt" )]
+ [TrialGlobalLimit("AfterStopCannNotOpt")]
//[Authorize(Policy = IRaCISPolicy.IQC)]
public async Task DeleteQCChallenge(Guid qcChallengeId)
{
@@ -209,7 +209,7 @@ namespace IRaCIS.Core.Application.Image.QA
///
///
[HttpPost("{trialId:guid}")]
- [TrialGlobalLimit( "AfterStopCannNotOpt" )]
+ [TrialGlobalLimit("AfterStopCannNotOpt")]
// [Authorize(Policy = IRaCISPolicy.CRC_IQC)]
public async Task AddQCChallengeReply(QADialogCommand qaDialogCommand)
{
@@ -244,7 +244,7 @@ namespace IRaCIS.Core.Application.Image.QA
///
///
[HttpPost("{trialId:guid}")]
- [TrialGlobalLimit( "AfterStopCannNotOpt" )]
+ [TrialGlobalLimit("AfterStopCannNotOpt")]
//[Authorize(Policy = IRaCISPolicy.PM_APM_CRC)]
public async Task AddCheckChallengeReply(CheckChallengeDialogCommand checkDialogCommand)
{
@@ -284,7 +284,7 @@ namespace IRaCIS.Core.Application.Image.QA
///
///
[HttpPut("{trialId:guid}")]
- [TrialGlobalLimit( "AfterStopCannNotOpt" )]
+ [TrialGlobalLimit("AfterStopCannNotOpt")]
//[Authorize(Policy = IRaCISPolicy.PM_APM)]
public async Task CloseCheckChallenge(CloseCheckChallengeDto input)
{
@@ -320,7 +320,7 @@ namespace IRaCIS.Core.Application.Image.QA
///
///
[HttpPut("{trialId:guid}")]
- [TrialGlobalLimit( "AfterStopCannNotOpt" )]
+ [TrialGlobalLimit("AfterStopCannNotOpt")]
//[Authorize(Policy = IRaCISPolicy.PM_APM)]
[UnitOfWork]
public async Task SetCheckPass(SetCheckPassDt data)
@@ -367,7 +367,7 @@ namespace IRaCIS.Core.Application.Image.QA
///
///
[HttpPut("{trialId:guid}/{subjectVisitId:guid}")]
- [TrialGlobalLimit( "AfterStopCannNotOpt" )]
+ [TrialGlobalLimit("AfterStopCannNotOpt")]
//[Authorize(Policy = IRaCISPolicy.CRC)]
public async Task CRCRequstCheckBack(Guid subjectVisitId)
{
@@ -413,7 +413,7 @@ namespace IRaCIS.Core.Application.Image.QA
[HttpPut("{trialId:guid}/{subjectVisitId:guid}")]
//[Authorize(Policy = IRaCISPolicy.PM_APM)]
- [TrialGlobalLimit( "AfterStopCannNotOpt" )]
+ [TrialGlobalLimit("AfterStopCannNotOpt")]
public async Task RejectCheckBack(Guid subjectVisitId)
{
//if (_userInfo.UserTypeEnumInt != (int)UserTypeEnum.ProjectManager && _userInfo.UserTypeEnumInt != (int)UserTypeEnum.APM)
@@ -446,7 +446,7 @@ namespace IRaCIS.Core.Application.Image.QA
///
///
[HttpPut("{trialId:guid}/{subjectVisitId:guid}")]
- [TrialGlobalLimit( "AfterStopCannNotOpt" )]
+ [TrialGlobalLimit("AfterStopCannNotOpt")]
//[Authorize(Policy = IRaCISPolicy.PM_APM)]
[UnitOfWork]
public async Task CheckBack(Guid subjectVisitId)
@@ -525,7 +525,7 @@ namespace IRaCIS.Core.Application.Image.QA
/// 添加或者更新 QC核对问题列表 两个人不能同时操作,就算意外进去了,提交数据,也不会覆盖前一个人数据, 后台已经做好判断
///
[HttpPost("{trialId:guid}/{subjectVisitId:guid}/{trialQCProcess:int}/{currentQCType:int}")]
- [TrialGlobalLimit( "AfterStopCannNotOpt" )]
+ [TrialGlobalLimit("AfterStopCannNotOpt")]
//[Authorize(Policy = IRaCISPolicy.IQC)]
public async Task AddOrUpdateQCQuestionAnswerList(QCQuestionAnswerCommand[] qcQuestionAnswerCommands, Guid trialId, Guid subjectVisitId, [FromRoute] TrialQCProcess trialQCProcess, [FromRoute] CurrentQC currentQCType)
{
@@ -597,7 +597,7 @@ namespace IRaCIS.Core.Application.Image.QA
///
///
[HttpPut("{trialId:guid}/{subjectVisitId:guid}/{studyId:guid}/{seriesId:guid}/{state:int}")]
- [TrialGlobalLimit( "AfterStopCannNotOpt" )]
+ [TrialGlobalLimit("AfterStopCannNotOpt")]
//[Authorize(Policy = IRaCISPolicy.IQC)]
public async Task SetSeriesState(Guid subjectVisitId, Guid studyId, Guid seriesId, int state)
{
@@ -659,12 +659,80 @@ namespace IRaCIS.Core.Application.Image.QA
return ResponseOutput.Ok(await _dicomStudyRepository.SaveChangesAsync());
}
+ ///
+ /// 1、设置为不读片,2 设置为读片(取消 先前设置为不读片) 4 设置为删除(数据库记录软删除) 5 恢复为未删除
+ ///
+ ///
+ ///
+ ///
+ ///
+ ///
+ [HttpPut("{trialId:guid}/{subjectVisitId:guid}/{seriesId:guid}/{instanceId:guid}/{state:int}")]
+ [TrialGlobalLimit("AfterStopCannNotOpt")]
+ public async Task SetInstanceState(Guid subjectVisitId, Guid seriesId, Guid instanceId, int state)
+ {
+
+ await VerifyIsCanQCAsync(null, subjectVisitId);
+
+ var instance = (await _dicomInstanceRepository.Where(t => t.Id == instanceId, true).IgnoreQueryFilters().FirstOrDefaultAsync()).IfNullThrowException();
+
+
+ if (state == 1)
+ {
+ instance.IsReading = false;
+ }
+ else if (state == 2)
+ {
+ instance.IsReading = true;
+ }
+ else if (state == 4)
+ {
+ instance.IsDeleted = true;
+
+ var series = (await _dicomSeriesRepository.Where(t => t.Id == seriesId, true).IgnoreQueryFilters().FirstOrDefaultAsync()).IfNullThrowException();
+
+ series.InstanceCount = series.InstanceCount - 1;
+
+ var study = (await _dicomStudyRepository.Where(t => t.Id == series.StudyId, true).IgnoreQueryFilters().FirstOrDefaultAsync()).IfNullThrowException();
+
+ study.InstanceCount = study.InstanceCount - 1;
+
+ ////删除到最后一个instance
+ //if (series.InstanceCount == 0)
+ //{
+ // series.IsDeleted = true;
+ //}
+
+
+
+ }
+ else if (state == 5)
+ {
+ instance.IsDeleted = false;
+
+ var series = (await _dicomSeriesRepository.Where(t => t.Id == seriesId, true).IgnoreQueryFilters().FirstOrDefaultAsync()).IfNullThrowException();
+
+ series.InstanceCount = series.InstanceCount + 1;
+
+ var study = (await _dicomStudyRepository.Where(t => t.Id == series.StudyId, true).IgnoreQueryFilters().FirstOrDefaultAsync()).IfNullThrowException();
+
+ study.InstanceCount = study.InstanceCount + 1;
+
+
+ }
+
+ return ResponseOutput.Ok(await _dicomStudyRepository.SaveChangesAsync());
+ }
+
+
+
+
///
///type 1 :study 2: series 3:非dicom QC修改检查部位和 拍片类型
///
///
[HttpPost("{trialId:guid}")]
- [TrialGlobalLimit( "AfterStopCannNotOpt" )]
+ [TrialGlobalLimit("AfterStopCannNotOpt")]
// [Authorize(Policy = IRaCISPolicy.CRC_IQC)]
public async Task UpdateModality(UpdateModalityCommand updateModalityCommand)
{
@@ -744,7 +812,7 @@ namespace IRaCIS.Core.Application.Image.QA
///
/// SeriesCount
[HttpPost, Route("{trialId:guid}/{subjectVisitId:guid}")]
- [TrialGlobalLimit( "AfterStopCannNotOpt" )]
+ [TrialGlobalLimit("AfterStopCannNotOpt")]
[UnitOfWork]
// [Authorize(Policy = IRaCISPolicy.CRC_IQC)]
public async Task DeleteStudyList(Guid[] ids, Guid subjectVisitId, Guid trialId)
@@ -848,7 +916,7 @@ namespace IRaCIS.Core.Application.Image.QA
/// 替换当前领取人
[HttpPut("{trialId:guid}/{subjectVisitId:guid}")]
//[Authorize(Policy = IRaCISPolicy.IQC)]
- [TrialGlobalLimit( "AfterStopCannNotOpt" )]
+ [TrialGlobalLimit("AfterStopCannNotOpt")]
public async Task ReplaceQCTaskActionUser(Guid trialId, Guid subjectVisitId)
{
var dbSubjectVisit = (await _subjectVisitRepository.FirstOrDefaultAsync(t => t.Id == subjectVisitId)).IfNullThrowException();
@@ -994,7 +1062,7 @@ namespace IRaCIS.Core.Application.Image.QA
/// true 获取 false是取消领取
///
[HttpPut("{trialId:guid}/{subjectVisitId:guid}/{obtaionOrCancel:bool}")]
- [TrialGlobalLimit( "AfterStopCannNotOpt" )]
+ [TrialGlobalLimit("AfterStopCannNotOpt")]
//[Authorize(Policy = IRaCISPolicy.IQC)]
public async Task ObtainOrCancelQCTask(Guid trialId, Guid subjectVisitId, bool obtaionOrCancel)
{
@@ -1219,7 +1287,7 @@ namespace IRaCIS.Core.Application.Image.QA
///
///
[HttpPost]
- [TrialGlobalLimit( "AfterStopCannNotOpt" )]
+ [TrialGlobalLimit("AfterStopCannNotOpt")]
//[Authorize(Policy = IRaCISPolicy.CRC)]
public async Task CRCRequestToQC(CRCRequestToQCCommand cRCRequestToQCCommand)
{
@@ -1507,7 +1575,7 @@ namespace IRaCIS.Core.Application.Image.QA
///
///
[HttpPost("{trialId:guid}/{subjectVisitId:guid}/{auditState:int}")]
- [TrialGlobalLimit( "AfterStopCannNotOpt" )]
+ [TrialGlobalLimit("AfterStopCannNotOpt")]
//[Authorize(Policy = IRaCISPolicy.IQC)]
[UnitOfWork]
public async Task QCPassedOrFailed(Guid trialId, Guid subjectVisitId, [FromRoute] AuditStateEnum auditState)
@@ -1741,7 +1809,7 @@ namespace IRaCIS.Core.Application.Image.QA
///
///
[HttpPut("{trialId:guid}/{subjectVisitId:guid}/{setOrCancel:bool}")]
- [TrialGlobalLimit( "AfterStopCannNotOpt" )]
+ [TrialGlobalLimit("AfterStopCannNotOpt")]
//[Authorize(Policy = IRaCISPolicy.IQC)]
public async Task SetVisitUrgent(Guid trialId, Guid subjectVisitId, bool setOrCancel)
{
@@ -1779,7 +1847,7 @@ namespace IRaCIS.Core.Application.Image.QA
///
///
[HttpPut("{trialId:guid}/{subjectVisitId:guid}/{qcChallengeId:guid}")]
- [TrialGlobalLimit( "AfterStopCannNotOpt" )]
+ [TrialGlobalLimit("AfterStopCannNotOpt")]
//[Authorize(Policy = IRaCISPolicy.IQC)]
public async Task SetNeedReupload(Guid trialId, Guid qcChallengeId)
{
@@ -1880,7 +1948,7 @@ namespace IRaCIS.Core.Application.Image.QA
///
[HttpPost]
- [TrialGlobalLimit( "AfterStopCannNotOpt" )]
+ [TrialGlobalLimit("AfterStopCannNotOpt")]
//[Authorize(Policy = IRaCISPolicy.CRC)]
public async Task SetReuploadFinished(CRCReuploadFinishedCommand cRCReuploadFinishedCommand)
{
@@ -1993,7 +2061,7 @@ namespace IRaCIS.Core.Application.Image.QA
[HttpPut("{trialId:guid}/{subjectVisitId:guid}/{qcChallengeId:guid}")]
- [TrialGlobalLimit( "AfterStopCannNotOpt" )]
+ [TrialGlobalLimit("AfterStopCannNotOpt")]
//[Authorize(Policy = IRaCISPolicy.CRC)]
public async Task CRCRequestReUpload(Guid qcChallengeId)
{
@@ -2040,7 +2108,7 @@ namespace IRaCIS.Core.Application.Image.QA
///
[HttpPut("{trialId:guid}")]
- [TrialGlobalLimit( "AfterStopCannNotOpt" )]
+ [TrialGlobalLimit("AfterStopCannNotOpt")]
public async Task UpdateSubjectAndSVInfo(UploadSubjectAndVisitCommand command)
{
var dbSubjectVisit = (await _subjectVisitRepository.FirstOrDefaultAsync(t => t.Id == command.SubjectVisitId)).IfNullThrowException();
diff --git a/IRaCIS.Core.Application/Service/Visit/SubjectVisitService.cs b/IRaCIS.Core.Application/Service/Visit/SubjectVisitService.cs
index 6c405f19f..8f285ea61 100644
--- a/IRaCIS.Core.Application/Service/Visit/SubjectVisitService.cs
+++ b/IRaCIS.Core.Application/Service/Visit/SubjectVisitService.cs
@@ -237,6 +237,7 @@ namespace IRaCIS.Core.Application.Services
var studyIds = studyList.Select(t => t.StudyId).ToList();
var instanceList = await _dicomInstanceRepository.Where(t => studyIds.Contains(t.StudyId))
+ .WhereIf(isReading == 1, s => s.IsReading)
.Select(t => new { t.SeriesId, t.Id, t.InstanceNumber, t.Path, t.NumberOfFrames, t.HtmlPath }).ToListAsync();
foreach (var t in studyList)
@@ -497,8 +498,8 @@ namespace IRaCIS.Core.Application.Services
}).ToListAsync();
var studyIds = dicomStudyList.Select(t => t.StudyId).ToList();
- var instanceList = await _dicomInstanceRepository.Where(t => studyIds.Contains(t.StudyId))
- .Select(t => new { t.SeriesId, t.Id, t.InstanceNumber, t.Path, t.NumberOfFrames, t.WindowCenter, t.WindowWidth, t.HtmlPath }).ToListAsync();
+ var instanceList = await _dicomInstanceRepository.Where(t => studyIds.Contains(t.StudyId) && t.IsReading)
+ .Select(t => new { t.SeriesId, t.Id, t.InstanceNumber, t.Path, t.NumberOfFrames, t.WindowCenter, t.WindowWidth, t.HtmlPath,t.IsReading }).ToListAsync();
List seriesLists = await _dicomSeriesRepository.Where(s => studyIds.Contains(s.StudyId))
.WhereIf(isManualGenerate == false, t => t.IsReading)
diff --git a/IRaCIS.Core.Domain/Image/DicomInstance.cs b/IRaCIS.Core.Domain/Image/DicomInstance.cs
index a6c22faa3..a69dbeba4 100644
--- a/IRaCIS.Core.Domain/Image/DicomInstance.cs
+++ b/IRaCIS.Core.Domain/Image/DicomInstance.cs
@@ -2,7 +2,7 @@
[Comment("归档 - Instance表")]
[Table("DicomInstance")]
-public class DicomInstance : BaseFullAuditEntity, IEntitySeqId
+public class DicomInstance : BaseFullDeleteAuditEntity, IEntitySeqId
{
#region 导航属性
[JsonIgnore]
@@ -75,4 +75,6 @@ public class DicomInstance : BaseFullAuditEntity, IEntitySeqId
public string WindowWidth { get; set; } = null!;
+
+ public bool IsReading { get; set; } = true;
}
diff --git a/IRaCIS.Core.Infra.EFCore/Migrations/20250213021502_AddInstanceIsReading.Designer.cs b/IRaCIS.Core.Infra.EFCore/Migrations/20250213021502_AddInstanceIsReading.Designer.cs
new file mode 100644
index 000000000..b1338f1e3
--- /dev/null
+++ b/IRaCIS.Core.Infra.EFCore/Migrations/20250213021502_AddInstanceIsReading.Designer.cs
@@ -0,0 +1,18581 @@
+//
+using System;
+using IRaCIS.Core.Infra.EFCore;
+using Microsoft.EntityFrameworkCore;
+using Microsoft.EntityFrameworkCore.Infrastructure;
+using Microsoft.EntityFrameworkCore.Metadata;
+using Microsoft.EntityFrameworkCore.Migrations;
+using Microsoft.EntityFrameworkCore.Storage.ValueConversion;
+
+#nullable disable
+
+namespace IRaCIS.Core.Infra.EFCore.Migrations
+{
+ [DbContext(typeof(IRaCISDBContext))]
+ [Migration("20250213021502_AddInstanceIsReading")]
+ partial class AddInstanceIsReading
+ {
+ ///
+ protected override void BuildTargetModel(ModelBuilder modelBuilder)
+ {
+#pragma warning disable 612, 618
+ modelBuilder
+ .HasAnnotation("ProductVersion", "8.0.10")
+ .HasAnnotation("Relational:MaxIdentifierLength", 128);
+
+ SqlServerModelBuilderExtensions.UseIdentityColumns(modelBuilder);
+
+ modelBuilder.Entity("IRaCIS.Core.Domain.Models.Attachment", b =>
+ {
+ b.Property("Id")
+ .HasColumnType("uniqueidentifier");
+
+ b.Property("Code")
+ .IsRequired()
+ .HasMaxLength(400)
+ .HasColumnType("nvarchar(400)")
+ .HasComment("编码");
+
+ b.Property("CreateTime")
+ .HasColumnType("datetime2");
+
+ b.Property("CreateUserId")
+ .HasColumnType("uniqueidentifier");
+
+ b.Property("DoctorId")
+ .HasColumnType("uniqueidentifier");
+
+ b.Property("ExpiryDate")
+ .HasColumnType("datetime2")
+ .HasComment("过期时间");
+
+ b.Property("FileName")
+ .IsRequired()
+ .HasMaxLength(400)
+ .HasColumnType("nvarchar(400)");
+
+ b.Property("IsOfficial")
+ .HasColumnType("bit")
+ .HasComment("是否正式简历");
+
+ b.Property("Language")
+ .HasColumnType("int")
+ .HasComment("1 中文 2为英文");
+
+ b.Property("Path")
+ .IsRequired()
+ .HasMaxLength(1000)
+ .HasColumnType("nvarchar(1000)");
+
+ b.Property("Type")
+ .IsRequired()
+ .HasMaxLength(400)
+ .HasColumnType("nvarchar(400)")
+ .HasComment("文件类型名");
+
+ b.HasKey("Id");
+
+ b.HasIndex("CreateUserId");
+
+ b.HasIndex("DoctorId");
+
+ b.ToTable("Attachment", t =>
+ {
+ t.HasComment("医生 - 简历|证书 文档表");
+ });
+ });
+
+ modelBuilder.Entity("IRaCIS.Core.Domain.Models.CRO", b =>
+ {
+ b.Property("Id")
+ .HasColumnType("uniqueidentifier");
+
+ b.Property("CROCode")
+ .IsRequired()
+ .HasMaxLength(400)
+ .HasColumnType("nvarchar(400)");
+
+ b.Property("CROName")
+ .IsRequired()
+ .HasMaxLength(400)
+ .HasColumnType("nvarchar(400)");
+
+ b.Property("CRONameCN")
+ .IsRequired()
+ .HasMaxLength(400)
+ .HasColumnType("nvarchar(400)");
+
+ b.Property("CreateTime")
+ .HasColumnType("datetime2");
+
+ b.Property("CreateUserId")
+ .HasColumnType("uniqueidentifier");
+
+ b.Property("IsTrialLevel")
+ .HasColumnType("bit")
+ .HasComment("是否是项目级别");
+
+ b.Property("TrialId")
+ .HasColumnType("uniqueidentifier");
+
+ b.Property("UpdateTime")
+ .HasColumnType("datetime2");
+
+ b.Property("UpdateUserId")
+ .HasColumnType("uniqueidentifier");
+
+ b.HasKey("Id");
+
+ b.HasIndex("CreateUserId");
+
+ b.ToTable("CROCompany", t =>
+ {
+ t.HasComment("机构 - CRO");
+ });
+ });
+
+ modelBuilder.Entity("IRaCIS.Core.Domain.Models.CheckChallengeDialog", b =>
+ {
+ b.Property("Id")
+ .HasColumnType("uniqueidentifier");
+
+ b.Property("CreateTime")
+ .HasColumnType("datetime2");
+
+ b.Property("CreateUserId")
+ .HasColumnType("uniqueidentifier");
+
+ b.Property("IsCRCNeedReply")
+ .HasColumnType("bit")
+ .HasComment("CRC是否需要回复 前端使用");
+
+ b.Property("ParamInfo")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)")
+ .HasComment("核查的检查信息Json");
+
+ b.Property("SubjectVisitId")
+ .HasColumnType("uniqueidentifier");
+
+ b.Property("TalkContent")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("UserTypeEnum")
+ .HasColumnType("int")
+ .HasComment("核查过程中的操作用户类型");
+
+ b.HasKey("Id");
+
+ b.HasIndex("CreateUserId");
+
+ b.HasIndex("SubjectVisitId");
+
+ b.ToTable("CheckChallengeDialog", t =>
+ {
+ t.HasComment("一致性核查 - 对话记录表");
+ });
+ });
+
+ modelBuilder.Entity("IRaCIS.Core.Domain.Models.ClinicalAnswerRowInfo", b =>
+ {
+ b.Property("Id")
+ .HasColumnType("uniqueidentifier");
+
+ b.Property("ClinicalFormId")
+ .HasColumnType("uniqueidentifier")
+ .HasComment("表单Id");
+
+ b.Property("CreateTime")
+ .HasColumnType("datetime2");
+
+ b.Property("CreateUserId")
+ .HasColumnType("uniqueidentifier");
+
+ b.Property("QuestionId")
+ .HasColumnType("uniqueidentifier")
+ .HasComment("问题Id");
+
+ b.Property("RowIndex")
+ .HasColumnType("int");
+
+ b.Property("SubjectId")
+ .HasColumnType("uniqueidentifier")
+ .HasComment("受试者Id");
+
+ b.HasKey("Id");
+
+ b.HasIndex("CreateUserId");
+
+ b.ToTable("ClinicalAnswerRowInfo", t =>
+ {
+ t.HasComment("受试者 - 临床表单表格问题行记录");
+ });
+ });
+
+ modelBuilder.Entity("IRaCIS.Core.Domain.Models.ClinicalDataSystemSet", b =>
+ {
+ b.Property("Id")
+ .HasColumnType("uniqueidentifier");
+
+ b.Property("ClinicalDataLevel")
+ .HasColumnType("int");
+
+ b.Property("ClinicalDataSetEnName")
+ .IsRequired()
+ .HasMaxLength(400)
+ .HasColumnType("nvarchar(400)");
+
+ b.Property("ClinicalDataSetEnum")
+ .HasColumnType("int")
+ .HasComment("枚举(字典里面取的)");
+
+ b.Property("ClinicalDataSetName")
+ .IsRequired()
+ .HasMaxLength(400)
+ .HasColumnType("nvarchar(400)");
+
+ b.Property("ClinicalUploadType")
+ .HasColumnType("int")
+ .HasComment("上传方式");
+
+ b.Property("CreateTime")
+ .HasColumnType("datetime2");
+
+ b.Property("CreateUserId")
+ .HasColumnType("uniqueidentifier");
+
+ b.Property("CriterionEnumListStr")
+ .IsRequired()
+ .HasMaxLength(1000)
+ .HasColumnType("nvarchar(1000)");
+
+ b.Property("EnFileName")
+ .IsRequired()
+ .HasMaxLength(400)
+ .HasColumnType("nvarchar(400)");
+
+ b.Property("EnPath")
+ .IsRequired()
+ .HasMaxLength(400)
+ .HasColumnType("nvarchar(400)");
+
+ b.Property("FileName")
+ .IsRequired()
+ .HasMaxLength(400)
+ .HasColumnType("nvarchar(400)");
+
+ b.Property("IsApply")
+ .HasColumnType("bit")
+ .HasComment("是否应用");
+
+ b.Property("IsEnable")
+ .HasColumnType("bit");
+
+ b.Property("Path")
+ .IsRequired()
+ .HasMaxLength(1000)
+ .HasColumnType("nvarchar(1000)");
+
+ b.Property("UploadRole")
+ .HasColumnType("int");
+
+ b.HasKey("Id");
+
+ b.HasIndex("CreateUserId");
+
+ b.ToTable("ClinicalDataSystemSet", t =>
+ {
+ t.HasComment("系统 - 临床数据配置");
+ });
+ });
+
+ modelBuilder.Entity("IRaCIS.Core.Domain.Models.ClinicalDataTrialSet", b =>
+ {
+ b.Property("Id")
+ .HasColumnType("uniqueidentifier");
+
+ b.Property("ClinicalDataLevel")
+ .HasColumnType("int")
+ .HasComment("临床级别");
+
+ b.Property("ClinicalDataSetEnName")
+ .IsRequired()
+ .HasMaxLength(400)
+ .HasColumnType("nvarchar(400)");
+
+ b.Property("ClinicalDataSetName")
+ .IsRequired()
+ .HasMaxLength(400)
+ .HasColumnType("nvarchar(400)");
+
+ b.Property("ClinicalUploadType")
+ .HasColumnType("int")
+ .HasComment("上传方式");
+
+ b.Property("CreateTime")
+ .HasColumnType("datetime2");
+
+ b.Property("CreateUserId")
+ .HasColumnType("uniqueidentifier");
+
+ b.Property("CriterionEnumListStr")
+ .IsRequired()
+ .HasMaxLength(1000)
+ .HasColumnType("nvarchar(1000)");
+
+ b.Property("EnFileName")
+ .IsRequired()
+ .HasMaxLength(400)
+ .HasColumnType("nvarchar(400)");
+
+ b.Property("EnPath")
+ .IsRequired()
+ .HasMaxLength(400)
+ .HasColumnType("nvarchar(400)");
+
+ b.Property("FileName")
+ .IsRequired()
+ .HasMaxLength(400)
+ .HasColumnType("nvarchar(400)");
+
+ b.Property("IsApply")
+ .HasColumnType("bit")
+ .HasComment("是否应用");
+
+ b.Property("IsConfirm")
+ .HasColumnType("bit");
+
+ b.Property("Path")
+ .IsRequired()
+ .HasMaxLength(1000)
+ .HasColumnType("nvarchar(1000)");
+
+ b.Property("SystemClinicalDataSetId")
+ .HasColumnType("uniqueidentifier");
+
+ b.Property("TrialId")
+ .HasColumnType("uniqueidentifier");
+
+ b.Property("UploadRole")
+ .HasColumnType("int");
+
+ b.HasKey("Id");
+
+ b.HasIndex("CreateUserId");
+
+ b.HasIndex("SystemClinicalDataSetId");
+
+ b.HasIndex("TrialId");
+
+ b.ToTable("ClinicalDataTrialSet", t =>
+ {
+ t.HasComment("项目 - 临床数据适应标准配置");
+ });
+ });
+
+ modelBuilder.Entity("IRaCIS.Core.Domain.Models.ClinicalForm", b =>
+ {
+ b.Property("Id")
+ .HasColumnType("uniqueidentifier");
+
+ b.Property("CheckDate")
+ .HasColumnType("datetime2")
+ .HasComment("检查日期");
+
+ b.Property("ClinicalDataTrialSetId")
+ .HasColumnType("uniqueidentifier");
+
+ b.Property("CreateTime")
+ .HasColumnType("datetime2");
+
+ b.Property("CreateUserId")
+ .HasColumnType("uniqueidentifier");
+
+ b.Property("PicturePath")
+ .IsRequired()
+ .HasMaxLength(1000)
+ .HasColumnType("nvarchar(1000)")
+ .HasComment("截图地址");
+
+ b.Property("ReadingId")
+ .HasColumnType("uniqueidentifier");
+
+ b.Property("SubjectId")
+ .HasColumnType("uniqueidentifier")
+ .HasComment("受试者Id");
+
+ b.Property("TrialId")
+ .HasColumnType("uniqueidentifier");
+
+ b.Property("VisitId")
+ .HasColumnType("uniqueidentifier");
+
+ b.HasKey("Id");
+
+ b.HasIndex("ClinicalDataTrialSetId");
+
+ b.HasIndex("CreateUserId");
+
+ b.HasIndex("SubjectId");
+
+ b.ToTable("ClinicalForm", t =>
+ {
+ t.HasComment("受试者 - 临床表单");
+ });
+ });
+
+ modelBuilder.Entity("IRaCIS.Core.Domain.Models.ClinicalQuestionAnswer", b =>
+ {
+ b.Property("Id")
+ .HasColumnType("uniqueidentifier");
+
+ b.Property("Answer")
+ .IsRequired()
+ .HasMaxLength(1000)
+ .HasColumnType("nvarchar(1000)");
+
+ b.Property("ClinicalDataTrialSetId")
+ .HasColumnType("uniqueidentifier");
+
+ b.Property("ClinicalFormId")
+ .HasColumnType("uniqueidentifier")
+ .HasComment("表单Id");
+
+ b.Property("CreateTime")
+ .HasColumnType("datetime2");
+
+ b.Property("CreateUserId")
+ .HasColumnType("uniqueidentifier");
+
+ b.Property("QuestionId")
+ .HasColumnType("uniqueidentifier")
+ .HasComment("问题Id");
+
+ b.Property("SubjectId")
+ .HasColumnType("uniqueidentifier")
+ .HasComment("受试者Id");
+
+ b.HasKey("Id");
+
+ b.HasIndex("ClinicalFormId");
+
+ b.HasIndex("CreateUserId");
+
+ b.ToTable("ClinicalQuestionAnswer", t =>
+ {
+ t.HasComment("受试者 - 临床表单问题答案");
+ });
+ });
+
+ modelBuilder.Entity("IRaCIS.Core.Domain.Models.ClinicalTableAnswer", b =>
+ {
+ b.Property("Id")
+ .HasColumnType("uniqueidentifier");
+
+ b.Property("Answer")
+ .IsRequired()
+ .HasMaxLength(1000)
+ .HasColumnType("nvarchar(1000)")
+ .HasComment("答案");
+
+ b.Property("ClinicalFormId")
+ .HasColumnType("uniqueidentifier")
+ .HasComment("表单Id");
+
+ b.Property("CreateTime")
+ .HasColumnType("datetime2");
+
+ b.Property("CreateUserId")
+ .HasColumnType("uniqueidentifier");
+
+ b.Property("QuestionId")
+ .HasColumnType("uniqueidentifier")
+ .HasComment("问题Id");
+
+ b.Property("RowId")
+ .HasColumnType("uniqueidentifier")
+ .HasComment("答案行的Id");
+
+ b.Property("SubjectId")
+ .HasColumnType("uniqueidentifier")
+ .HasComment("受试者Id");
+
+ b.Property("TableQuestionId")
+ .HasColumnType("uniqueidentifier");
+
+ b.HasKey("Id");
+
+ b.HasIndex("CreateUserId");
+
+ b.HasIndex("RowId");
+
+ b.ToTable("ClinicalTableAnswer", t =>
+ {
+ t.HasComment("受试者 - 临床表单表格问题答案");
+ });
+ });
+
+ modelBuilder.Entity("IRaCIS.Core.Domain.Models.CommonDocument", b =>
+ {
+ b.Property("Id")
+ .HasColumnType("uniqueidentifier");
+
+ b.Property("BusinessScenarioEnum")
+ .HasColumnType("int")
+ .HasComment("业务场景");
+
+ b.Property("Code")
+ .IsRequired()
+ .HasMaxLength(400)
+ .HasColumnType("nvarchar(400)");
+
+ b.Property("CreateTime")
+ .HasColumnType("datetime2");
+
+ b.Property("CreateUserId")
+ .HasColumnType("uniqueidentifier");
+
+ b.Property("CriterionTypeEnum")
+ .HasColumnType("int")
+ .HasComment("系统标准枚举");
+
+ b.Property("DeleteUserId")
+ .HasColumnType("uniqueidentifier");
+
+ b.Property("DeletedTime")
+ .HasColumnType("datetime2");
+
+ b.Property("Description")
+ .IsRequired()
+ .HasMaxLength(400)
+ .HasColumnType("nvarchar(400)");
+
+ b.Property("FileTypeEnum")
+ .HasColumnType("int")
+ .HasComment("类型-上传|导出|邮件附件");
+
+ b.Property("IsDeleted")
+ .HasColumnType("bit");
+
+ b.Property("Name")
+ .IsRequired()
+ .HasMaxLength(400)
+ .HasColumnType("nvarchar(400)");
+
+ b.Property("NameCN")
+ .IsRequired()
+ .HasMaxLength(400)
+ .HasColumnType("nvarchar(400)");
+
+ b.Property("Path")
+ .IsRequired()
+ .HasMaxLength(400)
+ .HasColumnType("nvarchar(400)");
+
+ b.Property("UpdateTime")
+ .HasColumnType("datetime2");
+
+ b.Property("UpdateUserId")
+ .HasColumnType("uniqueidentifier");
+
+ b.HasKey("Id");
+
+ b.HasIndex("CreateUserId");
+
+ b.ToTable("CommonDocument", t =>
+ {
+ t.HasComment("数据上传 | 数据导出 | 邮件附件 文件记录表 (需要同步)");
+ });
+ });
+
+ modelBuilder.Entity("IRaCIS.Core.Domain.Models.CriterionNidusSystem", b =>
+ {
+ b.Property("Id")
+ .HasColumnType("uniqueidentifier");
+
+ b.Property("CreateTime")
+ .HasColumnType("datetime2");
+
+ b.Property("CreateUserId")
+ .HasColumnType("uniqueidentifier");
+
+ b.Property("CriterionId")
+ .HasColumnType("uniqueidentifier");
+
+ b.Property("IsSystemCriterion")
+ .HasColumnType("bit");
+
+ b.Property("LesionType")
+ .HasColumnType("int")
+ .HasComment("病灶类型");
+
+ b.Property("OrganType")
+ .HasColumnType("int")
+ .HasComment("器官类型");
+
+ b.HasKey("Id");
+
+ b.HasIndex("CreateUserId");
+
+ b.HasIndex("CriterionId");
+
+ b.ToTable("CriterionNidusSystem", t =>
+ {
+ t.HasComment("系统标准 - 病灶器官表 (需要同步)");
+ });
+ });
+
+ modelBuilder.Entity("IRaCIS.Core.Domain.Models.CriterionNidusTrial", b =>
+ {
+ b.Property("Id")
+ .HasColumnType("uniqueidentifier");
+
+ b.Property("CreateTime")
+ .HasColumnType("datetime2");
+
+ b.Property("CreateUserId")
+ .HasColumnType("uniqueidentifier");
+
+ b.Property("CriterionId")
+ .HasColumnType("uniqueidentifier");
+
+ b.Property("LesionType")
+ .HasColumnType("int");
+
+ b.Property("OrganType")
+ .HasColumnType("int");
+
+ b.HasKey("Id");
+
+ b.HasIndex("CreateUserId");
+
+ b.ToTable("CriterionNidusTrial", t =>
+ {
+ t.HasComment("项目标准 - 病灶器官表");
+ });
+ });
+
+ modelBuilder.Entity("IRaCIS.Core.Domain.Models.DataInspection", b =>
+ {
+ b.Property("Id")
+ .HasColumnType("uniqueidentifier");
+
+ b.Property("BatchId")
+ .HasColumnType("uniqueidentifier")
+ .HasComment("批次Id");
+
+ b.Property("ChildrenTypeId")
+ .HasColumnType("uniqueidentifier")
+ .HasComment("子类");
+
+ b.Property("CreateTime")
+ .HasColumnType("datetime2");
+
+ b.Property("CreateUserId")
+ .HasColumnType("uniqueidentifier");
+
+ b.Property("CreateUserName")
+ .IsRequired()
+ .HasMaxLength(400)
+ .HasColumnType("nvarchar(400)")
+ .HasComment("创建人姓名");
+
+ b.Property("CreateUserRealName")
+ .IsRequired()
+ .HasMaxLength(400)
+ .HasColumnType("nvarchar(400)");
+
+ b.Property("DoctorUserId")
+ .HasColumnType("uniqueidentifier")
+ .HasComment("阅片医生");
+
+ b.Property("EntityName")
+ .IsRequired()
+ .HasMaxLength(400)
+ .HasColumnType("nvarchar(400)")
+ .HasComment("被稽查实体名");
+
+ b.Property("GeneralId")
+ .HasColumnType("uniqueidentifier")
+ .HasComment("要稽查对象Id");
+
+ b.Property("IP")
+ .IsRequired()
+ .HasMaxLength(400)
+ .HasColumnType("nvarchar(400)");
+
+ b.Property("Identification")
+ .IsRequired()
+ .HasMaxLength(400)
+ .HasColumnType("nvarchar(400)")
+ .HasComment("标识");
+
+ b.Property("IsFrontAdd")
+ .HasColumnType("bit")
+ .HasComment("是否是前端添加");
+
+ b.Property("IsSign")
+ .HasColumnType("bit");
+
+ b.Property("JsonDetail")
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("LastJsonDetail")
+ .HasColumnType("nvarchar(max)")
+ .HasComment("上一条json");
+
+ b.Property("ModuleTypeId")
+ .HasColumnType("uniqueidentifier");
+
+ b.Property("ObjectRelationParentId")
+ .HasColumnType("uniqueidentifier")
+ .HasComment("被稽查对象外键1");
+
+ b.Property("ObjectRelationParentId2")
+ .HasColumnType("uniqueidentifier");
+
+ b.Property("ObjectRelationParentId3")
+ .HasColumnType("uniqueidentifier");
+
+ b.Property("ObjectTypeId")
+ .HasColumnType("uniqueidentifier");
+
+ b.Property("OptTypeId")
+ .HasColumnType("uniqueidentifier");
+
+ b.Property("ParentId")
+ .HasColumnType("uniqueidentifier")
+ .HasComment("父ID");
+
+ b.Property("Reason")
+ .IsRequired()
+ .HasMaxLength(400)
+ .HasColumnType("nvarchar(400)");
+
+ b.Property("RoleName")
+ .IsRequired()
+ .HasMaxLength(400)
+ .HasColumnType("nvarchar(400)")
+ .HasComment("角色名称");
+
+ b.Property("SignId")
+ .HasColumnType("uniqueidentifier");
+
+ b.Property("SubjectId")
+ .HasColumnType("uniqueidentifier");
+
+ b.Property("SubjectVisitId")
+ .HasColumnType("uniqueidentifier");
+
+ b.Property("TrialId")
+ .HasColumnType("uniqueidentifier");
+
+ b.Property("TrialReadingCriterionId")
+ .HasColumnType("uniqueidentifier");
+
+ b.Property("TrialSiteId")
+ .HasColumnType("uniqueidentifier");
+
+ b.Property("VisitStageId")
+ .HasColumnType("uniqueidentifier")
+ .HasComment("访视计划ID");
+
+ b.Property("VisitTaskId")
+ .HasColumnType("uniqueidentifier");
+
+ b.HasKey("Id");
+
+ b.HasIndex("CreateUserId");
+
+ b.HasIndex("TrialReadingCriterionId");
+
+ b.HasIndex("VisitTaskId");
+
+ b.ToTable("DataInspection", t =>
+ {
+ t.HasComment("稽查 - 记录表");
+ });
+ });
+
+ modelBuilder.Entity("IRaCIS.Core.Domain.Models.DicomInstance", b =>
+ {
+ b.Property("SeqId")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("uniqueidentifier");
+
+ b.Property("Anonymize")
+ .HasColumnType("bit");
+
+ b.Property("CPIStatus")
+ .HasColumnType("bit");
+
+ b.Property("CreateTime")
+ .HasColumnType("datetime2");
+
+ b.Property("CreateUserId")
+ .HasColumnType("uniqueidentifier");
+
+ b.Property("DeleteUserId")
+ .HasColumnType("uniqueidentifier");
+
+ b.Property("DeletedTime")
+ .HasColumnType("datetime2");
+
+ b.Property("FileSize")
+ .HasColumnType("bigint");
+
+ b.Property("FrameOfReferenceUID")
+ .IsRequired()
+ .HasMaxLength(400)
+ .HasColumnType("nvarchar(400)");
+
+ b.Property("HtmlPath")
+ .IsRequired()
+ .HasMaxLength(1000)
+ .HasColumnType("nvarchar(1000)");
+
+ b.Property("Id")
+ .HasColumnType("uniqueidentifier");
+
+ b.Property("ImageColumns")
+ .HasColumnType("int");
+
+ b.Property("ImageRows")
+ .HasColumnType("int");
+
+ b.Property("ImagerPixelSpacing")
+ .IsRequired()
+ .HasMaxLength(400)
+ .HasColumnType("nvarchar(400)");
+
+ b.Property("InstanceNumber")
+ .HasColumnType("int");
+
+ b.Property("InstanceTime")
+ .HasColumnType("datetime2");
+
+ b.Property("IsDeleted")
+ .HasColumnType("bit");
+
+ b.Property("IsReading")
+ .HasColumnType("bit");
+
+ b.Property("NumberOfFrames")
+ .HasColumnType("int");
+
+ b.Property("Path")
+ .IsRequired()
+ .HasMaxLength(1000)
+ .HasColumnType("nvarchar(1000)");
+
+ b.Property("PixelSpacing")
+ .IsRequired()
+ .HasMaxLength(400)
+ .HasColumnType("nvarchar(400)");
+
+ b.Property("SeriesId")
+ .HasColumnType("uniqueidentifier");
+
+ b.Property("SeriesInstanceUid")
+ .IsRequired()
+ .HasMaxLength(400)
+ .HasColumnType("nvarchar(400)");
+
+ b.Property("SliceLocation")
+ .HasColumnType("int");
+
+ b.Property("SliceThickness")
+ .IsRequired()
+ .HasMaxLength(400)
+ .HasColumnType("nvarchar(400)");
+
+ b.Property("SopInstanceUid")
+ .IsRequired()
+ .HasMaxLength(400)
+ .HasColumnType("nvarchar(400)");
+
+ b.Property("StudyId")
+ .HasColumnType("uniqueidentifier");
+
+ b.Property("StudyInstanceUid")
+ .IsRequired()
+ .HasMaxLength(400)
+ .HasColumnType("nvarchar(400)");
+
+ b.Property("SubjectId")
+ .HasColumnType("uniqueidentifier");
+
+ b.Property("SubjectVisitId")
+ .HasColumnType("uniqueidentifier");
+
+ b.Property("TrialId")
+ .HasColumnType("uniqueidentifier");
+
+ b.Property("UpdateTime")
+ .HasColumnType("datetime2");
+
+ b.Property("UpdateUserId")
+ .HasColumnType("uniqueidentifier");
+
+ b.Property("WindowCenter")
+ .IsRequired()
+ .HasMaxLength(400)
+ .HasColumnType("nvarchar(400)");
+
+ b.Property("WindowWidth")
+ .IsRequired()
+ .HasMaxLength(400)
+ .HasColumnType("nvarchar(400)");
+
+ b.HasKey("SeqId");
+
+ b.HasIndex("CreateUserId");
+
+ b.HasIndex("SeriesId");
+
+ b.HasIndex("StudyId");
+
+ b.ToTable("DicomInstance", t =>
+ {
+ t.HasComment("归档 - Instance表");
+ });
+ });
+
+ modelBuilder.Entity("IRaCIS.Core.Domain.Models.DicomSeries", b =>
+ {
+ b.Property("SeqId")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("uniqueidentifier");
+
+ b.Property("AcquisitionNumber")
+ .IsRequired()
+ .HasMaxLength(400)
+ .HasColumnType("nvarchar(400)");
+
+ b.Property("AcquisitionTime")
+ .IsRequired()
+ .HasMaxLength(400)
+ .HasColumnType("nvarchar(400)");
+
+ b.Property("BodyPartExamined")
+ .IsRequired()
+ .HasMaxLength(400)
+ .HasColumnType("nvarchar(400)");
+
+ b.Property("BodyPartForEdit")
+ .IsRequired()
+ .HasMaxLength(400)
+ .HasColumnType("nvarchar(400)");
+
+ b.Property("CreateTime")
+ .HasColumnType("datetime2");
+
+ b.Property("CreateUserId")
+ .HasColumnType("uniqueidentifier");
+
+ b.Property("DeleteUserId")
+ .HasColumnType("uniqueidentifier");
+
+ b.Property("DeletedTime")
+ .HasColumnType("datetime2");
+
+ b.Property("Description")
+ .IsRequired()
+ .HasMaxLength(400)
+ .HasColumnType("nvarchar(400)");
+
+ b.Property("Id")
+ .HasColumnType("uniqueidentifier");
+
+ b.Property("ImageOrientationPatient")
+ .IsRequired()
+ .HasMaxLength(400)
+ .HasColumnType("nvarchar(400)");
+
+ b.Property("ImagePositionPatient")
+ .IsRequired()
+ .HasMaxLength(400)
+ .HasColumnType("nvarchar(400)");
+
+ b.Property("ImageResizePath")
+ .IsRequired()
+ .HasMaxLength(1000)
+ .HasColumnType("nvarchar(1000)");
+
+ b.Property("ImagerPixelSpacing")
+ .IsRequired()
+ .HasMaxLength(400)
+ .HasColumnType("nvarchar(400)");
+
+ b.Property("InstanceCount")
+ .HasColumnType("int");
+
+ b.Property("IsDeleted")
+ .HasColumnType("bit");
+
+ b.Property("IsReading")
+ .HasColumnType("bit");
+
+ b.Property("Modality")
+ .IsRequired()
+ .HasMaxLength(400)
+ .HasColumnType("nvarchar(400)");
+
+ b.Property("ProtocolName")
+ .IsRequired()
+ .HasMaxLength(400)
+ .HasColumnType("nvarchar(400)");
+
+ b.Property("SequenceName")
+ .IsRequired()
+ .HasMaxLength(400)
+ .HasColumnType("nvarchar(400)");
+
+ b.Property("SeriesInstanceUid")
+ .IsRequired()
+ .HasMaxLength(400)
+ .HasColumnType("nvarchar(400)");
+
+ b.Property("SeriesNumber")
+ .HasColumnType("int");
+
+ b.Property("SeriesTime")
+ .HasColumnType("datetime2");
+
+ b.Property("SliceThickness")
+ .IsRequired()
+ .HasMaxLength(400)
+ .HasColumnType("nvarchar(400)");
+
+ b.Property("StudyId")
+ .HasColumnType("uniqueidentifier");
+
+ b.Property("StudyInstanceUid")
+ .IsRequired()
+ .HasMaxLength(400)
+ .HasColumnType("nvarchar(400)");
+
+ b.Property("SubjectId")
+ .HasColumnType("uniqueidentifier");
+
+ b.Property("SubjectVisitId")
+ .HasColumnType("uniqueidentifier");
+
+ b.Property("TrialId")
+ .HasColumnType("uniqueidentifier");
+
+ b.Property("TriggerTime")
+ .IsRequired()
+ .HasMaxLength(400)
+ .HasColumnType("nvarchar(400)");
+
+ b.Property("UpdateTime")
+ .HasColumnType("datetime2");
+
+ b.Property("UpdateUserId")
+ .HasColumnType("uniqueidentifier");
+
+ b.Property("VisitTaskId")
+ .HasColumnType("uniqueidentifier");
+
+ b.HasKey("SeqId");
+
+ b.HasIndex("CreateUserId");
+
+ b.HasIndex("StudyId");
+
+ b.ToTable("DicomSeries", t =>
+ {
+ t.HasComment("归档 - 序列表");
+ });
+ });
+
+ modelBuilder.Entity("IRaCIS.Core.Domain.Models.DicomStudy", b =>
+ {
+ b.Property("SeqId")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("uniqueidentifier")
+ .HasComment("序列Id 避免内存移动");
+
+ b.Property("AccessionNumber")
+ .IsRequired()
+ .HasMaxLength(400)
+ .HasColumnType("nvarchar(400)");
+
+ b.Property