From 5250cd524aee8af78b42913d7a14266c986c0683 Mon Sep 17 00:00:00 2001 From: hang <872297557@qq.com> Date: Wed, 13 Nov 2024 18:30:39 +0800 Subject: [PATCH] =?UTF-8?q?=E9=98=85=E7=89=87=E6=8E=A5=E5=8F=A3=E8=BF=94?= =?UTF-8?q?=E5=9B=9E=E4=B9=8B=E5=89=8D=E7=9A=84=E5=8F=82=E6=95=B0=E5=AF=B9?= =?UTF-8?q?=E6=8E=A5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Service/Allocation/DTO/VisitTaskViewModel.cs | 16 ++++++++++++++++ .../Service/Allocation/VisitTaskService.cs | 14 ++++++++++---- .../Service/Allocation/_MapConfig.cs | 8 +++++--- .../Service/ImageAndDoc/DTO/DicomSeriesModel.cs | 3 +++ .../ReadingImageTask/ReadingImageTaskService.cs | 2 +- 5 files changed, 35 insertions(+), 8 deletions(-) diff --git a/IRaCIS.Core.Application/Service/Allocation/DTO/VisitTaskViewModel.cs b/IRaCIS.Core.Application/Service/Allocation/DTO/VisitTaskViewModel.cs index 9617e2969..1aaa80c99 100644 --- a/IRaCIS.Core.Application/Service/Allocation/DTO/VisitTaskViewModel.cs +++ b/IRaCIS.Core.Application/Service/Allocation/DTO/VisitTaskViewModel.cs @@ -108,6 +108,8 @@ namespace IRaCIS.Core.Application.ViewModel public class VisitTaskViewBasic { + public string SubjectShortName { get; set; } + public Guid Id { get; set; } public Guid TrialId { get; set; } @@ -386,6 +388,13 @@ namespace IRaCIS.Core.Application.ViewModel public ReReadingApplyState ReReadingApplyState { get; set; } public DateTime? SuggesteFinishedTime { get; set; } + + #region HIR + + public List PatientList { get; set; } + + #endregion + } public class IRUnReadSubjectView @@ -518,6 +527,13 @@ namespace IRaCIS.Core.Application.ViewModel public class VisitTaskQuery : PageInput { + #region HIR + + public DateTime? BeginSignDate { get; set; } + + public DateTime? EndSignDate { get; set; } + #endregion + [NotDefault] public Guid TrialId { get; set; } diff --git a/IRaCIS.Core.Application/Service/Allocation/VisitTaskService.cs b/IRaCIS.Core.Application/Service/Allocation/VisitTaskService.cs index ad852802e..7ed3f4b63 100644 --- a/IRaCIS.Core.Application/Service/Allocation/VisitTaskService.cs +++ b/IRaCIS.Core.Application/Service/Allocation/VisitTaskService.cs @@ -1185,7 +1185,7 @@ public class VisitTaskService(IRepository _visitTaskRepository, return ResponseOutput.Ok(result, new { - IsReadingTaskViewInOrder = isReadingTaskViewInOrder, + IsReadingTaskViewInOrder = isReadingTaskViewInOrder==ReadingOrder.InOrder, RandomReadInfo = iRUnReadOut, ReadingTool = readingTool, IseCRFShowInDicomReading = criterionConfig.IseCRFShowInDicomReading, @@ -1478,10 +1478,16 @@ public class VisitTaskService(IRepository _visitTaskRepository, var visitTaskQueryable = _visitTaskRepository.Where(t => t.TrialId == inQuery.TrialId) - .Where(t => t.DoctorUserId == _userInfo.Id && t.ReadingTaskState == ReadingTaskState.HaveSigned)//该医生 已经签名的数据 + .Where(t => /*t.DoctorUserId == _userInfo.Id &&*/ t.ReadingTaskState == ReadingTaskState.HaveSigned)//该医生 已经签名的数据 + .WhereIf(_userInfo.UserTypeEnumInt == (int)UserTypeEnum.PI, t => t.DoctorUser.UserTypeEnum == UserTypeEnum.PI) + .WhereIf(!string.IsNullOrWhiteSpace(inQuery.PatientIdStr), t => t.Subject.SubjectPatientList.Any(t => t.Patient.PatientIdStr.Contains(inQuery.PatientIdStr))) + .WhereIf(!string.IsNullOrWhiteSpace(inQuery.PatientName), t => t.Subject.SubjectPatientList.Any(t => t.Patient.PatientName.Contains(inQuery.PatientName))) + .WhereIf(!string.IsNullOrWhiteSpace(inQuery.PatientSex), t => t.Subject.SubjectPatientList.Any(t => t.Patient.PatientSex.Contains(inQuery.PatientSex))) + .WhereIf(inQuery.PIAuditState != null, t => t.PIAuditState == inQuery.PIAuditState) + .WhereIf(inQuery.BeginSignDate != null, t => t.SignTime >= inQuery.BeginSignDate) + .WhereIf(inQuery.EndSignDate != null, t => t.SignTime <= inQuery.EndSignDate) - - .WhereIf(inQuery.TrialSiteId != null, t => t.Subject.TrialSiteId == inQuery.TrialSiteId) + //.WhereIf(inQuery.TrialSiteId != null, t => t.Subject.TrialSiteId == inQuery.TrialSiteId) .WhereIf(inQuery.SubjectId != null, t => t.SubjectId == inQuery.SubjectId) .WhereIf(inQuery.IsUrgent != null, t => t.IsUrgent == inQuery.IsUrgent) .WhereIf(inQuery.ReadingCategory != null, t => t.ReadingCategory == inQuery.ReadingCategory) diff --git a/IRaCIS.Core.Application/Service/Allocation/_MapConfig.cs b/IRaCIS.Core.Application/Service/Allocation/_MapConfig.cs index 82ee8e51f..3b79c5f20 100644 --- a/IRaCIS.Core.Application/Service/Allocation/_MapConfig.cs +++ b/IRaCIS.Core.Application/Service/Allocation/_MapConfig.cs @@ -132,7 +132,8 @@ namespace IRaCIS.Core.Application.Service .ForMember(o => o.IsReadingShowPreviousResults, t => t.MapFrom(u => u.TrialReadingCriterion.IsReadingShowPreviousResults)) .ForMember(o => o.DigitPlaces, t => t.MapFrom(u => u.TrialReadingCriterion.DigitPlaces)) .ForMember(o => o.IseCRFShowInDicomReading, t => t.MapFrom(u => u.TrialReadingCriterion.IseCRFShowInDicomReading)) - .ForMember(o => o.CriterionType, t => t.MapFrom(u => u.TrialReadingCriterion.CriterionType)); + .ForMember(o => o.CriterionType, t => t.MapFrom(u => u.TrialReadingCriterion.CriterionType)) + .ForMember(o => o.SubjectShortName, t => t.MapFrom(u => u.Subject.ShortName)); CreateMap().IncludeBase() @@ -184,8 +185,9 @@ namespace IRaCIS.Core.Application.Service CreateMap().IncludeBase() .ForMember(o => o.TrialSiteId, t => t.MapFrom(u => u.Subject.TrialSiteId)) - .ForMember(o => o.TrialSiteCode, t => t.MapFrom(u => u.IsAnalysisCreate == true ? u.BlindTrialSiteCode : u.Subject.TrialSite.TrialSiteCode)) - .ForMember(o => o.SubjectCode, t => t.MapFrom(u => u.IsAnalysisCreate == true ? u.BlindSubjectCode : u.Subject.Code)); + //.ForMember(o => o.TrialSiteCode, t => t.MapFrom(u => u.IsAnalysisCreate == true ? u.BlindTrialSiteCode : u.Subject.TrialSite.TrialSiteCode)) + .ForMember(o => o.SubjectCode, t => t.MapFrom(u => u.IsAnalysisCreate == true ? u.BlindSubjectCode : u.Subject.Code)) + .ForMember(d => d.PatientList, u => u.MapFrom(s => s.Subject.SubjectPatientList)); diff --git a/IRaCIS.Core.Application/Service/ImageAndDoc/DTO/DicomSeriesModel.cs b/IRaCIS.Core.Application/Service/ImageAndDoc/DTO/DicomSeriesModel.cs index 6717099d1..9dd548228 100644 --- a/IRaCIS.Core.Application/Service/ImageAndDoc/DTO/DicomSeriesModel.cs +++ b/IRaCIS.Core.Application/Service/ImageAndDoc/DTO/DicomSeriesModel.cs @@ -42,6 +42,9 @@ namespace IRaCIS.Core.Application.Contracts.Dicom.DTO public List InstanceInfoList { get; set; } = new List(); + public List InstanceList => InstanceInfoList.Select(t => t.Id).ToList(); + public List InstancePathList => InstanceInfoList.Select(t => t.Path).ToList(); + public bool IsExistMutiFrames => InstanceInfoList.Any(t => t.NumberOfFrames > 1); diff --git a/IRaCIS.Core.Application/Service/Reading/ReadingImageTask/ReadingImageTaskService.cs b/IRaCIS.Core.Application/Service/Reading/ReadingImageTask/ReadingImageTaskService.cs index 733d7bc52..575c66817 100644 --- a/IRaCIS.Core.Application/Service/Reading/ReadingImageTask/ReadingImageTaskService.cs +++ b/IRaCIS.Core.Application/Service/Reading/ReadingImageTask/ReadingImageTaskService.cs @@ -3213,7 +3213,7 @@ namespace IRaCIS.Core.Application.Service await _visitTaskRepository.SaveChangesAsync(); - await _trialEmailNoticeConfigService.BaseBusinessScenarioSendEmailAsync(visitTaskId); + //await _trialEmailNoticeConfigService.BaseBusinessScenarioSendEmailAsync(visitTaskId); }