From 78c707a01818c3f311a5205b593f4e771a82f232 Mon Sep 17 00:00:00 2001 From: he <109787524@qq.com> Date: Mon, 11 Nov 2024 11:34:42 +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 --- .../Reading/ReadingCriterion/ReadingQuestionService.cs | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/IRaCIS.Core.Application/Service/Reading/ReadingCriterion/ReadingQuestionService.cs b/IRaCIS.Core.Application/Service/Reading/ReadingCriterion/ReadingQuestionService.cs index fa89dc852..59e746a5e 100644 --- a/IRaCIS.Core.Application/Service/Reading/ReadingCriterion/ReadingQuestionService.cs +++ b/IRaCIS.Core.Application/Service/Reading/ReadingCriterion/ReadingQuestionService.cs @@ -578,7 +578,8 @@ namespace IRaCIS.Core.Application.Service "select","radio","class", }; var questionList = await _readingQuestionTrialRepository.Where(x => x.ReadingQuestionCriterionTrialId == inDto.ReadingQuestionCriterionTrialId) - .Where(x => types.Contains(x.Type)) + .Where(x => types.Contains(x.Type)||(x.Type=="number"&&x.TypeValue!=string.Empty)) + .WhereIf(inDto.Id != null, x => x.Id != inDto.Id && x.ParentId != inDto.Id) .Where(x => x.ReadingCriterionPageId == inDto.ReadingCriterionPageId) @@ -672,10 +673,10 @@ namespace IRaCIS.Core.Application.Service var types = new List() { - "select","radio" + "select","radio","class" }; var questionList = await _readingTableQuestionTrialRepository.Where(x => x.ReadingQuestionId == inDto.ReadingQuestionId) - .Where(x => types.Contains(x.Type)) + .Where(x => types.Contains(x.Type) || (x.Type == "number" && x.TypeValue != string.Empty)) .WhereIf(inDto.Id != null, x => x.Id != inDto.Id && x.ParentId != inDto.Id) .Select(x => new CriterionOtherQuestionOutDto()