From 6ec64c9744fa6e9a754d877265b0237dcc15a02e Mon Sep 17 00:00:00 2001 From: he <10978375@qq.com> Date: Thu, 1 Dec 2022 15:12:58 +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 --- IRaCIS.Core.Application/IRaCIS.Core.Application.xml | 9 +++++++++ .../Reading/ReadingCriterion/ReadingQuestionService.cs | 8 ++++---- 2 files changed, 13 insertions(+), 4 deletions(-) diff --git a/IRaCIS.Core.Application/IRaCIS.Core.Application.xml b/IRaCIS.Core.Application/IRaCIS.Core.Application.xml index 5005a479..fe575282 100644 --- a/IRaCIS.Core.Application/IRaCIS.Core.Application.xml +++ b/IRaCIS.Core.Application/IRaCIS.Core.Application.xml @@ -8717,6 +8717,15 @@ + + + 验证计算关系 + + + + + + 获取问题计算关系 diff --git a/IRaCIS.Core.Application/Service/Reading/ReadingCriterion/ReadingQuestionService.cs b/IRaCIS.Core.Application/Service/Reading/ReadingCriterion/ReadingQuestionService.cs index 58d6ae88..675cde70 100644 --- a/IRaCIS.Core.Application/Service/Reading/ReadingCriterion/ReadingQuestionService.cs +++ b/IRaCIS.Core.Application/Service/Reading/ReadingCriterion/ReadingQuestionService.cs @@ -402,7 +402,7 @@ namespace IRaCIS.Application.Services TrialReadingCriterionId = indto.ReadingQuestionCriterionTrialId, }); - var relation = relationList.Where(x => x.QuestionId == indto.Id).FirstOrDefault(); + var relation = relationList.FirstOrDefault(x => x.QuestionId == indto.Id); List calculateInfoList = new List(); try { @@ -414,7 +414,7 @@ namespace IRaCIS.Application.Services } - + relation.CalculateQuestionList = calculateInfoList; this.VerifyCalculateRelation(relationList, indto.Id.Value, indto.Id.Value); } @@ -629,7 +629,7 @@ namespace IRaCIS.Application.Services ReadingQuestionId = indto.ReadingQuestionId, }); - var relation = relationList.Where(x => x.QuestionId == indto.Id).FirstOrDefault(); + var relation = relationList.FirstOrDefault(x => x.QuestionId == indto.Id); List calculateInfoList = new List(); try { @@ -641,7 +641,7 @@ namespace IRaCIS.Application.Services } - + relation.CalculateQuestionList = calculateInfoList; this.VerifyCalculateRelation(relationList, indto.Id.Value, indto.Id.Value); }