From 80b877879c328e2766ead4d25dba89252d1f8d05 Mon Sep 17 00:00:00 2001
From: he <10978375@qq.com>
Date: Tue, 23 May 2023 09:33:17 +0800
Subject: [PATCH 1/4] =?UTF-8?q?=E4=BF=AE=E6=94=B9?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
.../ReadingImageTaskService.cs | 30 +++++++++----------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/IRaCIS.Core.Application/Service/Reading/ReadingImageTask/ReadingImageTaskService.cs b/IRaCIS.Core.Application/Service/Reading/ReadingImageTask/ReadingImageTaskService.cs
index 1c52065c3..5a337833e 100644
--- a/IRaCIS.Core.Application/Service/Reading/ReadingImageTask/ReadingImageTaskService.cs
+++ b/IRaCIS.Core.Application/Service/Reading/ReadingImageTask/ReadingImageTaskService.cs
@@ -150,23 +150,23 @@ namespace IRaCIS.Application.Services
//_userInfo.UserTypeId
return await _trialDocumentRepository.Where(x => x.TrialId == inDto.TrialId
- && x.TrialDocConfirmedUserList.Any(y => y.ConfirmUserId == _userInfo.Id)
+ && x.TrialDocConfirmedUserList.Any(y => y.ConfirmUserId == _userInfo.Id && y.ConfirmTime != null)
&& x.NeedConfirmedUserTypeList.Any(y => y.NeedConfirmUserTypeId == _userInfo.UserTypeId))
- .Where(t => t.FileType.Code == "2" || t.FileType.Code == "6")
- .Select(x => new GetManualListOutDto()
- {
- Id=x.Id,
- Name = x.Name,
- Path = x.Path
- }).ToListAsync();
- }
+ .Where(t => t.FileType.Code == "2" || t.FileType.Code == "6").IgnoreQueryFilters()
+ .Select(x => new GetManualListOutDto()
+ {
+ Id = x.Id,
+ Name = x.Name,
+ Path = x.Path
+ }).ToListAsync();
+ }
- ///
- /// 获取任务附加问题
- ///
- ///
- ///
- [HttpPost]
+ ///
+ /// 获取任务附加问题
+ ///
+ ///
+ ///
+ [HttpPost]
public async Task<(List, bool)> GetTaskAdditionalQuestion(GetTaskAdditionalQuestionInDto inDto)
{
From 36f236f69f8923fc9a378c86e47b965982bfe9f6 Mon Sep 17 00:00:00 2001
From: he <10978375@qq.com>
Date: Tue, 23 May 2023 10:35:21 +0800
Subject: [PATCH 2/4] =?UTF-8?q?=E4=BF=AE=E6=94=B9?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
.../Service/QC/DTO/QARecordViewModel.cs | 2 +-
.../Service/QC/QCListService.cs | 5 +++++
.../Reading/Interface/IReadingImageTaskService.cs | 2 ++
.../ReadingImageTask/ReadingImageTaskService.cs | 14 ++++++++++++--
4 files changed, 20 insertions(+), 3 deletions(-)
diff --git a/IRaCIS.Core.Application/Service/QC/DTO/QARecordViewModel.cs b/IRaCIS.Core.Application/Service/QC/DTO/QARecordViewModel.cs
index 98240a51a..346c40b64 100644
--- a/IRaCIS.Core.Application/Service/QC/DTO/QARecordViewModel.cs
+++ b/IRaCIS.Core.Application/Service/QC/DTO/QARecordViewModel.cs
@@ -255,7 +255,7 @@ namespace IRaCIS.Core.Application.Contracts.DTO
public class TrialVisitQADTO
{
-
+ public bool ExistsManual { get; set; }
public SubjectClinicalDataDto SubjectClinicalData { get; set; } = new SubjectClinicalDataDto();
public List NoneDicomStudyList { get; set; } = new List();
diff --git a/IRaCIS.Core.Application/Service/QC/QCListService.cs b/IRaCIS.Core.Application/Service/QC/QCListService.cs
index 5ede37c99..b5a41f3d9 100644
--- a/IRaCIS.Core.Application/Service/QC/QCListService.cs
+++ b/IRaCIS.Core.Application/Service/QC/QCListService.cs
@@ -21,15 +21,19 @@ namespace IRaCIS.Core.Application.Image.QA
private readonly IRepository _trialQCQuestionRepository;
private readonly IRepository _consistencyCheckFileRepository;
+ private IReadingImageTaskService _IReadingImageTaskService;
+
public QCListService(
IRepository subjectVisitRepository,
IRepository trialRepository,
IRepository clinicalDataTrialSet,
IRepository trialQCQuestionAnswerRepository,
IRepository trialQCQuestionRepository,
+ IReadingImageTaskService IReadingImageTaskService,
IRepository consistencyCheckFileRepository
)
{
+ this._IReadingImageTaskService = IReadingImageTaskService;
_subjectVisitRepository = subjectVisitRepository;
this._trialQCQuestionAnswerRepository = trialQCQuestionAnswerRepository;
this._trialQCQuestionRepository = trialQCQuestionRepository;
@@ -606,6 +610,7 @@ namespace IRaCIS.Core.Application.Image.QA
{
QCQuestionAnswerList = qacheckList,
StudyList = temp.StudyList,
+ ExistsManual= (await _IReadingImageTaskService.GetManualList(new GetManualListInDto() { TrialId = sv.TrialId })).Count() > 0,
SeriesList = temp.SeriesList,
RelationInfo = await GetVisitQCSubjectInfo(subjectVisitId),
NoneDicomStudyList = await _repository.Where(t => t.SubjectVisitId == subjectVisitId).ProjectTo(_mapper.ConfigurationProvider).ToListAsync(),
diff --git a/IRaCIS.Core.Application/Service/Reading/Interface/IReadingImageTaskService.cs b/IRaCIS.Core.Application/Service/Reading/Interface/IReadingImageTaskService.cs
index 79dfc0603..f87e5b68a 100644
--- a/IRaCIS.Core.Application/Service/Reading/Interface/IReadingImageTaskService.cs
+++ b/IRaCIS.Core.Application/Service/Reading/Interface/IReadingImageTaskService.cs
@@ -33,5 +33,7 @@ namespace IRaCIS.Core.Application.Contracts
Task SubmitOncologyReadingInfo(SubmitOncologyReadingInfoInDto inDto);
Task AddOncologyTask(Guid oncologModuleId);
+
+ Task> GetManualList(GetManualListInDto inDto)
}
}
\ No newline at end of file
diff --git a/IRaCIS.Core.Application/Service/Reading/ReadingImageTask/ReadingImageTaskService.cs b/IRaCIS.Core.Application/Service/Reading/ReadingImageTask/ReadingImageTaskService.cs
index 5a337833e..2d1f40204 100644
--- a/IRaCIS.Core.Application/Service/Reading/ReadingImageTask/ReadingImageTaskService.cs
+++ b/IRaCIS.Core.Application/Service/Reading/ReadingImageTask/ReadingImageTaskService.cs
@@ -147,12 +147,22 @@ namespace IRaCIS.Application.Services
public async Task> GetManualList(GetManualListInDto inDto)
{
UserTypeEnum userType = (UserTypeEnum)_userInfo.UserTypeEnumInt;
- //_userInfo.UserTypeId
+
+
+ List canViewUserType = new List()
+ {
+ UserTypeEnum.IndependentReviewer,
+ UserTypeEnum.IQC,
+
+ };
return await _trialDocumentRepository.Where(x => x.TrialId == inDto.TrialId
&& x.TrialDocConfirmedUserList.Any(y => y.ConfirmUserId == _userInfo.Id && y.ConfirmTime != null)
&& x.NeedConfirmedUserTypeList.Any(y => y.NeedConfirmUserTypeId == _userInfo.UserTypeId))
- .Where(t => t.FileType.Code == "2" || t.FileType.Code == "6").IgnoreQueryFilters()
+ .WhereIf(userType== UserTypeEnum.IndependentReviewer, t => t.FileType.Code == "2" || t.FileType.Code == "6")
+ .WhereIf(userType == UserTypeEnum.IQC, t => t.FileType.Code == "4" || t.FileType.Code == "5")
+ .WhereIf(!canViewUserType.Contains(userType),t=>false)
+ .IgnoreQueryFilters()
.Select(x => new GetManualListOutDto()
{
Id = x.Id,
From d7829c371f6cbfa3a032b82d3f5814329a60ca11 Mon Sep 17 00:00:00 2001
From: he <10978375@qq.com>
Date: Tue, 23 May 2023 10:40:38 +0800
Subject: [PATCH 3/4] =?UTF-8?q?=E4=BF=AE=E6=94=B9?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
.../Service/Reading/Interface/IReadingImageTaskService.cs | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/IRaCIS.Core.Application/Service/Reading/Interface/IReadingImageTaskService.cs b/IRaCIS.Core.Application/Service/Reading/Interface/IReadingImageTaskService.cs
index f87e5b68a..88728c9a4 100644
--- a/IRaCIS.Core.Application/Service/Reading/Interface/IReadingImageTaskService.cs
+++ b/IRaCIS.Core.Application/Service/Reading/Interface/IReadingImageTaskService.cs
@@ -34,6 +34,6 @@ namespace IRaCIS.Core.Application.Contracts
Task AddOncologyTask(Guid oncologModuleId);
- Task> GetManualList(GetManualListInDto inDto)
+ Task> GetManualList(GetManualListInDto inDto);
}
}
\ No newline at end of file
From 2cd8e2546638f5f15af60ecf16748f20e4b157f7 Mon Sep 17 00:00:00 2001
From: he <10978375@qq.com>
Date: Tue, 23 May 2023 10:58:09 +0800
Subject: [PATCH 4/4] =?UTF-8?q?=E4=BF=AE=E6=94=B9?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
.../IRECIST1Point1CalculateService.cs | 4 +++
.../ReadingCalculate/PCWG3CalculateService.cs | 7 +++++
.../RECIST1Point1CalculateService.cs | 7 +++++
.../RECIST1Point1_BMCalculateService.cs | 6 ++++
IRaCIS.Core.Domain.Share/Reading/ReadEnum.cs | 30 +++++++++++++++----
5 files changed, 49 insertions(+), 5 deletions(-)
diff --git a/IRaCIS.Core.Application/Service/ReadingCalculate/IRECIST1Point1CalculateService.cs b/IRaCIS.Core.Application/Service/ReadingCalculate/IRECIST1Point1CalculateService.cs
index c2373fe8d..8fcfa0e0e 100644
--- a/IRaCIS.Core.Application/Service/ReadingCalculate/IRECIST1Point1CalculateService.cs
+++ b/IRaCIS.Core.Application/Service/ReadingCalculate/IRECIST1Point1CalculateService.cs
@@ -766,7 +766,11 @@ namespace IRaCIS.Core.Application.Service.ReadingCalculate
///
public async Task VerifyVisitTaskQuestions(VerifyVisitTaskQuestionsInDto inDto)
{
+ if (await _readingTaskQuestionAnswerRepository.AnyAsync(x => x.ReadingQuestionTrial.QuestionType == QuestionType.ImageQualityAssessment && x.VisitTaskId == inDto.VisitTaskId && x.Answer == ImageQualityEvaluation.Abnormal.GetEnumInt()))
+ {
+ return;
+ }
var tableAnswerList = await _readingTableQuestionAnswerRepository.Where(x => x.VisitTaskId == inDto.VisitTaskId && (x.Answer == string.Empty || x.Answer == null)
&& x.ReadingTableQuestionTrial.QuestionMark == QuestionMark.State
)
diff --git a/IRaCIS.Core.Application/Service/ReadingCalculate/PCWG3CalculateService.cs b/IRaCIS.Core.Application/Service/ReadingCalculate/PCWG3CalculateService.cs
index 845f43f6e..f396c0497 100644
--- a/IRaCIS.Core.Application/Service/ReadingCalculate/PCWG3CalculateService.cs
+++ b/IRaCIS.Core.Application/Service/ReadingCalculate/PCWG3CalculateService.cs
@@ -1027,6 +1027,13 @@ namespace IRaCIS.Core.Application.Service.ReadingCalculate
public async Task VerifyVisitTaskQuestions(VerifyVisitTaskQuestionsInDto inDto)
{
+
+ if (await _readingTaskQuestionAnswerRepository.AnyAsync(x => x.ReadingQuestionTrial.QuestionType == QuestionType.ImageQualityAssessment && x.VisitTaskId == inDto.VisitTaskId && x.Answer == ImageQualityEvaluation.Abnormal.GetEnumInt()))
+ {
+
+ return;
+ }
+
var tableAnswerList = await _readingTableQuestionAnswerRepository.Where(x => x.VisitTaskId == inDto.VisitTaskId && (x.Answer == string.Empty || x.Answer == null)
&& x.ReadingTableQuestionTrial.QuestionMark == QuestionMark.State
)
diff --git a/IRaCIS.Core.Application/Service/ReadingCalculate/RECIST1Point1CalculateService.cs b/IRaCIS.Core.Application/Service/ReadingCalculate/RECIST1Point1CalculateService.cs
index 85eee1514..c44e8815c 100644
--- a/IRaCIS.Core.Application/Service/ReadingCalculate/RECIST1Point1CalculateService.cs
+++ b/IRaCIS.Core.Application/Service/ReadingCalculate/RECIST1Point1CalculateService.cs
@@ -633,6 +633,13 @@ namespace IRaCIS.Core.Application.Service.ReadingCalculate
public async Task VerifyVisitTaskQuestions(VerifyVisitTaskQuestionsInDto inDto)
{
+ if (await _readingTaskQuestionAnswerRepository.AnyAsync(x => x.ReadingQuestionTrial.QuestionType == QuestionType.ImageQualityAssessment && x.VisitTaskId == inDto.VisitTaskId && x.Answer == ImageQualityEvaluation.Abnormal.GetEnumInt()))
+ {
+
+ return;
+ }
+
+
var tableAnswerList = await _readingTableQuestionAnswerRepository.Where(x => x.VisitTaskId == inDto.VisitTaskId && (x.Answer == string.Empty || x.Answer == null)
&& x.ReadingTableQuestionTrial.QuestionMark == QuestionMark.State
)
diff --git a/IRaCIS.Core.Application/Service/ReadingCalculate/RECIST1Point1_BMCalculateService.cs b/IRaCIS.Core.Application/Service/ReadingCalculate/RECIST1Point1_BMCalculateService.cs
index 3fd7eecc2..bd528675f 100644
--- a/IRaCIS.Core.Application/Service/ReadingCalculate/RECIST1Point1_BMCalculateService.cs
+++ b/IRaCIS.Core.Application/Service/ReadingCalculate/RECIST1Point1_BMCalculateService.cs
@@ -629,6 +629,12 @@ namespace IRaCIS.Core.Application.Service.ReadingCalculate
public async Task VerifyVisitTaskQuestions(VerifyVisitTaskQuestionsInDto inDto)
{
+ if (await _readingTaskQuestionAnswerRepository.AnyAsync(x => x.ReadingQuestionTrial.QuestionType == QuestionType.ImageQualityAssessment && x.VisitTaskId == inDto.VisitTaskId && x.Answer == ImageQualityEvaluation.Abnormal.GetEnumInt()))
+ {
+
+ return;
+ }
+
var tableAnswerList = await _readingTableQuestionAnswerRepository.Where(x => x.VisitTaskId == inDto.VisitTaskId && (x.Answer == string.Empty || x.Answer == null)
&& x.ReadingTableQuestionTrial.QuestionMark == QuestionMark.State
)
diff --git a/IRaCIS.Core.Domain.Share/Reading/ReadEnum.cs b/IRaCIS.Core.Domain.Share/Reading/ReadEnum.cs
index 7ed9a7783..e17780ed5 100644
--- a/IRaCIS.Core.Domain.Share/Reading/ReadEnum.cs
+++ b/IRaCIS.Core.Domain.Share/Reading/ReadEnum.cs
@@ -16,11 +16,26 @@ namespace IRaCIS.Core.Domain.Share
public static readonly string Group = "group";
}
+ ///
+ /// 影像质量评估
+ ///
+ public enum ImageQualityEvaluation
+ {
+ ///
+ /// 正常
+ ///
+ Normal = 1,
- ///
- /// 语言类型
- ///
- public enum LanguageType
+ ///
+ /// 不正常
+ ///
+ Abnormal = 2,
+ }
+
+ ///
+ /// 语言类型
+ ///
+ public enum LanguageType
{
///
@@ -1490,7 +1505,12 @@ namespace IRaCIS.Core.Domain.Share
///
IsBrainMetastasis =43,
-
+ ///
+ /// 影像质量评估
+ ///
+ ImageQualityAssessment=44,
+
+
}
///