From c64b8262667d0e67f8e021f853bac8f924b008f0 Mon Sep 17 00:00:00 2001 From: he <109787524@qq.com> Date: Wed, 21 Aug 2024 17:48:22 +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 --- .../Allocation/DTO/TaskConsistentRuleViewModel.cs | 9 ++++++++- .../Service/Allocation/TaskConsistentRuleService.cs | 12 ++++++------ 2 files changed, 14 insertions(+), 7 deletions(-) diff --git a/IRaCIS.Core.Application/Service/Allocation/DTO/TaskConsistentRuleViewModel.cs b/IRaCIS.Core.Application/Service/Allocation/DTO/TaskConsistentRuleViewModel.cs index 6dd8a45a8..9f73b9a4a 100644 --- a/IRaCIS.Core.Application/Service/Allocation/DTO/TaskConsistentRuleViewModel.cs +++ b/IRaCIS.Core.Application/Service/Allocation/DTO/TaskConsistentRuleViewModel.cs @@ -287,7 +287,14 @@ namespace IRaCIS.Core.Application.ViewModel } - + public class GetConsistentRuleOut + { + public TaskConsistentRuleBasic? ConsistentRuleBasic { get; set; } + /// + /// 任务展示访视 读片任务显示是否顺序 + /// + public ReadingOrder IsReadingTaskViewInOrder { get; set; } = ReadingOrder.InOrder; + } ///TaskConsistentRuleQuery 列表查询参数模型 public class TaskConsistentRuleQuery diff --git a/IRaCIS.Core.Application/Service/Allocation/TaskConsistentRuleService.cs b/IRaCIS.Core.Application/Service/Allocation/TaskConsistentRuleService.cs index 345a65d9b..c914ee5be 100644 --- a/IRaCIS.Core.Application/Service/Allocation/TaskConsistentRuleService.cs +++ b/IRaCIS.Core.Application/Service/Allocation/TaskConsistentRuleService.cs @@ -785,16 +785,16 @@ namespace IRaCIS.Core.Application.Service [HttpPost] - public async Task<(TaskConsistentRuleBasic?,object)> GetConsistentRule(TaskConsistentRuleQuery inQuery) + public async Task GetConsistentRule(TaskConsistentRuleQuery inQuery) { var IsReadingTaskViewInOrder = await _trialReadingCriterionRepository.Where(x => x.Id == inQuery.TrialReadingCriterionId).Select(x => x.IsReadingTaskViewInOrder).FirstNotNullAsync(); var result = await _taskConsistentRuleRepository.Where(t => t.TrialId == inQuery.TrialId && t.IsSelfAnalysis == inQuery.IsSelfAnalysis && t.TrialReadingCriterionId == inQuery.TrialReadingCriterionId).ProjectTo(_mapper.ConfigurationProvider).FirstOrDefaultAsync(); - return (result, - new { - IsReadingTaskViewInOrder= IsReadingTaskViewInOrder, - } - ); + return new GetConsistentRuleOut() + { + ConsistentRuleBasic = result, + IsReadingTaskViewInOrder = IsReadingTaskViewInOrder + }; } ///