From d7f19b18ec2350ee62376876b1c99c772256e198 Mon Sep 17 00:00:00 2001 From: he <10978375@qq.com> Date: Fri, 23 Sep 2022 15:11:05 +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/ReadingCalculateService.cs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/IRaCIS.Core.Application/Service/Reading/ReadingCalculateService.cs b/IRaCIS.Core.Application/Service/Reading/ReadingCalculateService.cs index eba4685b1..f72b3af05 100644 --- a/IRaCIS.Core.Application/Service/Reading/ReadingCalculateService.cs +++ b/IRaCIS.Core.Application/Service/Reading/ReadingCalculateService.cs @@ -669,9 +669,9 @@ namespace IRaCIS.Core.Application.Service var noTargetLesion = inDto.QuestionInfo.Where(x => x.QuestionType == QuestionType.NoTargetLesion).Select(x => x.Answer).FirstOrDefault(); var newLesions = inDto.QuestionInfo.Where(x => x.QuestionType == QuestionType.NewLesions).Select(x => x.Answer).FirstOrDefault(); var result = await _tumorAssessmentRepository.Where(x => - x.TargetLesion == (TargetAssessment)int.Parse(targetLesion?? TargetAssessment.NA.GetEnumInt()) && - x.NonTargetLesions == (NoTargetAssessment)int.Parse(noTargetLesion?? NoTargetAssessment.NA.GetEnumInt()) && - x.NewLesion == (NewLesionAssessment)int.Parse(newLesions?? NewLesionAssessment.NA.GetEnumInt())).Select(x => x.OverallEfficacy).ToListAsync(); + x.TargetLesion == (TargetAssessment)int.Parse(targetLesion.IsNullOrEmpty()? TargetAssessment.NA.GetEnumInt(): targetLesion) && + x.NonTargetLesions == (NoTargetAssessment)int.Parse(noTargetLesion.IsNullOrEmpty() ? NoTargetAssessment.NA.GetEnumInt(): noTargetLesion) && + x.NewLesion == (NewLesionAssessment)int.Parse(newLesions.IsNullOrEmpty() ? NewLesionAssessment.NA.GetEnumInt(): newLesions)).Select(x => x.OverallEfficacy).ToListAsync(); return result.Count == 0 ? OverallAssessment.NA.GetEnumInt() : result[0].GetEnumInt(); }