diff --git a/IRaCIS.Core.Application/Service/QC/QCOperationService.cs b/IRaCIS.Core.Application/Service/QC/QCOperationService.cs index e791e0342..94e4ca4a1 100644 --- a/IRaCIS.Core.Application/Service/QC/QCOperationService.cs +++ b/IRaCIS.Core.Application/Service/QC/QCOperationService.cs @@ -266,7 +266,7 @@ namespace IRaCIS.Core.Application.Image.QA if (!_subjectVisitRepository.Any(t => t.Id == subjectVisitId && !t.VisitTaskList.Any(u => u.TaskState == TaskState.Effect) && t.SubmitState == SubmitStateEnum.Submitted)) { - //已提交未生成任务的才允许申请 + //已提交、未生成任务的才允许申请 throw new BusinessValidationFailedException(_localizer["QCOperation_ShouldBeforeCheckPassed"]); } @@ -1360,6 +1360,11 @@ namespace IRaCIS.Core.Application.Image.QA return ResponseOutput.NotOk(_localizer["QCOperation_QCConfigFirst"], ApiResponseCodeEnum.NeedTips); } + if (_subjectVisitImageBackRecordReposiotry.Any(t => t.SubjectVisitId == subjectVisitId && t.ImageBackState == ImageBackStateEnum.None)) + { + //已申请的影像回退,不能领取 + throw new BusinessValidationFailedException(_localizer["QCOperation_HaveApplyedImageBackCanNotObtain"]); + } //if (await _subjectVisitRepository.AnyAsync(t => t.IsTake && // t.SubjectId != dbSubjectVisit.SubjectId && diff --git a/IRaCIS.Core.Infra.EFCore/Interceptor/AddDomainExt.cs b/IRaCIS.Core.Infra.EFCore/Interceptor/AddDomainExt.cs index 800dc9ec8..64fbc4f1a 100644 --- a/IRaCIS.Core.Infra.EFCore/Interceptor/AddDomainExt.cs +++ b/IRaCIS.Core.Infra.EFCore/Interceptor/AddDomainExt.cs @@ -367,7 +367,7 @@ public static class DBContext_Ext } - if ((originReReadingApplyState == ReReadingApplyState.DocotorHaveApplyed || originReReadingApplyState == ReReadingApplyState.TrialGroupHaveApplyed) && + if ((/*originReReadingApplyState == ReReadingApplyState.DocotorHaveApplyed ||*/ originReReadingApplyState == ReReadingApplyState.TrialGroupHaveApplyed) && (visitTask.ReReadingApplyState == ReReadingApplyState.Agree || visitTask.ReReadingApplyState == ReReadingApplyState.Reject)) { visitTask.AddDomainEvent(new HaveReadVisitTaskReReading() { SubjectId = visitTask.SubjectId, VisitTaskId = visitTask.Id, ReReadingApplyState = visitTask.ReReadingApplyState });