From bf9edb8425f81c6f4b184d3a38f383f5ecad7725 Mon Sep 17 00:00:00 2001 From: he <10978375@qq.com> Date: Tue, 14 Jun 2022 16:12:51 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E4=B8=80=E7=89=88?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- IRaCIS.Core.Application/IRaCIS.Core.Application.xml | 7 +++++++ .../Service/Reading/Dto/ReadingQuestionViewModel.cs | 4 ++++ .../Service/Reading/ReadingQuestionService.cs | 3 --- IRaCIS.Core.Application/Service/Reading/_MapConfig.cs | 6 ++++-- .../Reading/ReadingQuestionCriterionTrial.cs | 2 ++ IRaCIS.Core.Domain/Reading/ReadingQuestionTrial.cs | 3 +++ 6 files changed, 20 insertions(+), 5 deletions(-) diff --git a/IRaCIS.Core.Application/IRaCIS.Core.Application.xml b/IRaCIS.Core.Application/IRaCIS.Core.Application.xml index 542556a00..3c1c46962 100644 --- a/IRaCIS.Core.Application/IRaCIS.Core.Application.xml +++ b/IRaCIS.Core.Application/IRaCIS.Core.Application.xml @@ -4204,6 +4204,13 @@ + + + 设置项目标准是否生效 + + + + 获取项目问题标准(项目) diff --git a/IRaCIS.Core.Application/Service/Reading/Dto/ReadingQuestionViewModel.cs b/IRaCIS.Core.Application/Service/Reading/Dto/ReadingQuestionViewModel.cs index 716b1f1ea..703073129 100644 --- a/IRaCIS.Core.Application/Service/Reading/Dto/ReadingQuestionViewModel.cs +++ b/IRaCIS.Core.Application/Service/Reading/Dto/ReadingQuestionViewModel.cs @@ -397,6 +397,8 @@ namespace IRaCIS.Core.Application.Service.Reading.Dto /// 是否启用 /// public bool IsEnable { get; set; } + + public int QuestionCount { get; set; } } @@ -422,6 +424,8 @@ namespace IRaCIS.Core.Application.Service.Reading.Dto /// public bool IsEnable { get; set; } + public int QuestionCount { get; set; } + /// /// 是否是系统数据 /// diff --git a/IRaCIS.Core.Application/Service/Reading/ReadingQuestionService.cs b/IRaCIS.Core.Application/Service/Reading/ReadingQuestionService.cs index 3599c0bc2..132b7a5c4 100644 --- a/IRaCIS.Core.Application/Service/Reading/ReadingQuestionService.cs +++ b/IRaCIS.Core.Application/Service/Reading/ReadingQuestionService.cs @@ -280,9 +280,6 @@ namespace IRaCIS.Application.Services CreateQuestionRelation(ReadingQuestionCriterionTrialId, trialId, oldId, newId, systemQuesitonList, needQuestionList); }); - - - } /// diff --git a/IRaCIS.Core.Application/Service/Reading/_MapConfig.cs b/IRaCIS.Core.Application/Service/Reading/_MapConfig.cs index a1ee0ffda..883e886ca 100644 --- a/IRaCIS.Core.Application/Service/Reading/_MapConfig.cs +++ b/IRaCIS.Core.Application/Service/Reading/_MapConfig.cs @@ -51,7 +51,8 @@ namespace IRaCIS.Core.Application.Service #region 阅片问题 CreateMap(); - CreateMap(); + CreateMap() + .ForMember(d => d.QuestionCount, u => u.MapFrom(s => s.ReadingQuestionSystemList.Count())); CreateMap(); @@ -60,7 +61,8 @@ namespace IRaCIS.Core.Application.Service CreateMap(); - CreateMap(); + CreateMap() + .ForMember(d => d.QuestionCount, u => u.MapFrom(s => s.ReadingQuestionTrialList.Count())); CreateMap(); diff --git a/IRaCIS.Core.Domain/Reading/ReadingQuestionCriterionTrial.cs b/IRaCIS.Core.Domain/Reading/ReadingQuestionCriterionTrial.cs index 2bc4aa538..f70ddb97c 100644 --- a/IRaCIS.Core.Domain/Reading/ReadingQuestionCriterionTrial.cs +++ b/IRaCIS.Core.Domain/Reading/ReadingQuestionCriterionTrial.cs @@ -53,6 +53,8 @@ namespace IRaCIS.Core.Domain.Models /// [ForeignKey("TrialId")] public Trial Trial { get; set; } + + public List ReadingQuestionTrialList = new List(); } diff --git a/IRaCIS.Core.Domain/Reading/ReadingQuestionTrial.cs b/IRaCIS.Core.Domain/Reading/ReadingQuestionTrial.cs index 68e577ac7..e0918d74a 100644 --- a/IRaCIS.Core.Domain/Reading/ReadingQuestionTrial.cs +++ b/IRaCIS.Core.Domain/Reading/ReadingQuestionTrial.cs @@ -73,6 +73,9 @@ namespace IRaCIS.Core.Domain.Models [ForeignKey("ParentId")] public ReadingQuestionTrial ParentReadingQuestionTrial { get; set; } + [ForeignKey("ReadingQuestionCriterionTrialId")] + public ReadingQuestionCriterionTrial ReadingQuestionCriterionTrial { get; set; } + }