Uat_Study
he 2023-05-08 09:23:23 +08:00
parent 0aa981eea5
commit 7649e60d28
3 changed files with 16 additions and 5 deletions

View File

@ -1181,7 +1181,9 @@ namespace IRaCIS.Core.Application.Service.Reading.Dto
public List<GlobalQuestionInfo> AgreeOrNot { get; set; }
public List<GlobalQuestionInfo> AfterQuestionList { get; set; }
}
public List<LesionDto> LesionCountList { get; set; } = new List<LesionDto>();
}
public class GetGlobalQuestionType
{

View File

@ -230,8 +230,13 @@ namespace IRaCIS.Application.Services
VisitNum = x.SourceSubjectVisit.VisitNum,
IsBaseLine = x.SourceSubjectVisit.IsBaseLine,
VisitId = x.SourceSubjectVisitId.Value,
//CrterionDictionaryGroup= x.CrterionDictionaryGroup,
BeforeQuestionList = x.ReadingTaskQuestionAnswerList.Where(y => y.ReadingQuestionTrial.GlobalReadingShowType!=GlobalReadingShowType.NotShow).OrderBy(y => y.ReadingQuestionTrial.ShowOrder)
LesionCountList=x.LesionList.GroupBy(y=>y.ReadingQuestionTrial.LesionType).Select(x => new LesionDto
{
LesionType = x.Key.Value,
Count = x.ToList().Count()
}).ToList(),
//CrterionDictionaryGroup= x.CrterionDictionaryGroup,
BeforeQuestionList = x.ReadingTaskQuestionAnswerList.Where(y => y.ReadingQuestionTrial.GlobalReadingShowType!=GlobalReadingShowType.NotShow).OrderBy(y => y.ReadingQuestionTrial.ShowOrder)
.Select(y => new GlobalQuestionInfo()
{

View File

@ -110,8 +110,12 @@ namespace IRaCIS.Core.Application.Service.ReadingCalculate
var questionList = await _readingQuestionTrialRepository.Where(x => x.ReadingQuestionCriterionTrialId == criterionId && x.ShowQuestion != ShowQuestion.Hide).ToListAsync();
var tableQuestionList = await _readingTableQuestionTrialRepository.Where(x => x.TrialCriterionId == criterionId).OrderBy(x => x.ShowOrder).ToListAsync();
var tableAnsweRowInfos = await _readingTableAnswerRowInfoRepository.Where(x => x.VisitTaskId == indto.VisitTaskId).ProjectTo<TableAnsweRowInfo>(_mapper.ConfigurationProvider).ToListAsync();
var answers = await _readingTaskQuestionAnswerRepository.Where(x => visitTaskIds.Contains(x.VisitTaskId)).ToListAsync();
result.LesionCountList = tableAnsweRowInfos.GroupBy(x => x.LesionType).Select(x => new LesionDto
{
LesionType = x.Key.Value,
Count = x.ToList().Count()
}).ToList();
var answers = await _readingTaskQuestionAnswerRepository.Where(x => visitTaskIds.Contains(x.VisitTaskId)).ToListAsync();
var tableAnswers = await _readingTableQuestionAnswerRepository.Where(x => visitTaskIds.Contains(x.VisitTaskId)).ToListAsync();
var alltableAnsweRowInfos = await _readingTableAnswerRowInfoRepository.Where(x => visitTaskIds.Contains(x.VisitTaskId)).ToListAsync();