Uat_Study
he 2022-11-24 11:53:33 +08:00
parent b1eba88540
commit ab6a965a90
1 changed files with 14 additions and 0 deletions

View File

@ -133,8 +133,22 @@ namespace IRaCIS.Application.Services
}).ToListAsync();
var globalReadingQuestion = await _readingGlobalTaskInfoRepository.Where(x => x.GlobalTaskId == inDto.VisitTaskId).ToListAsync();
var criterionType = await _readingQuestionCriterionTrialRepository.Where(x => x.Id == taskInfo.TrialReadingCriterionId).Select(x => x.CriterionType).FirstOrDefaultAsync();
if (criterionType == CriterionType.PCWG3)
{
result.TaskList.ForEach(x =>
{
x.BeforeQuestionList.ForEach(y =>
{
var globalAnswer = globalReadingQuestion.Where(z => z.QuestionId == y.QuestionId).Select(z => z.Answer).FirstOrDefault();
y.Answer = globalAnswer.IsNullOrEmpty() ? y.Answer : globalAnswer;
});
});
}
result.TaskList.ForEach(x =>
{
x.AfterQuestionList = x.BeforeQuestionList.Where(x=>x.IsJudgeQuestion).GroupJoin(