From eaf486e7d3b5fa681668bd892bf0067908fe0fda Mon Sep 17 00:00:00 2001 From: he <10978375@qq.com> Date: Thu, 4 Aug 2022 11:51:11 +0800 Subject: [PATCH] =?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/ReadingImageTaskService.cs | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/IRaCIS.Core.Application/Service/Reading/ReadingImageTaskService.cs b/IRaCIS.Core.Application/Service/Reading/ReadingImageTaskService.cs index 11ecaec70..7e5710981 100644 --- a/IRaCIS.Core.Application/Service/Reading/ReadingImageTaskService.cs +++ b/IRaCIS.Core.Application/Service/Reading/ReadingImageTaskService.cs @@ -163,7 +163,6 @@ namespace IRaCIS.Application.Services // 找到对应的访视 - List oncologyVisits = await _visitTaskRepository.Where(x => x.ReadingCategory == ReadingCategory.Visit && x.SubjectId == visitTask.SubjectId && x.IsAnalysisCreate == visitTask.IsAnalysisCreate && x.TaskState == TaskState.Effect && x.VisitTaskNum < visitTask.VisitTaskNum) .Where(x => x.DoctorUserId == visitTask.DoctorUserId) @@ -192,6 +191,13 @@ namespace IRaCIS.Application.Services x.EvaluationReason = oncologyData.EvaluationReason; } + x.QuestionList.ForEach(z => + { + z.Answer = globalTaskReadingInfo.TaskList.Where(y => x.VisitTaskId == y.VisitTaskId).SelectMany(y => y.AfterQuestionList).Where(y => z.QuestionId == y.QuestionId).Select(y => y.Answer).FirstOrDefault(); + + }); + + x.IsHaveChange = globalTaskReadingInfo.TaskList.Where(y => x.VisitTaskId == y.VisitTaskId).SelectMany(y => y.AfterQuestionList).Any(y => y.IsHaveChange); x.VisitRemark = globalTaskReadingInfo.TaskList.Where(y => x.VisitTaskId == y.VisitTaskId).SelectMany(y => y.AfterQuestionList).Where(y => y.QuestionId == null).Select(x => x.Answer).FirstOrDefault() ?? String.Empty;