From 438e0947ac3e195913700820b894876db05712bc Mon Sep 17 00:00:00 2001 From: he <10978375@qq.com> Date: Wed, 5 Jul 2023 14:49:19 +0800 Subject: [PATCH] S-008 --- .../ClinicalData/ClinicalAnswerService.cs | 21 ++++++++++++------- .../Service/Reading/Dto/ClinicalAnswerDto.cs | 14 +++++++++++-- 2 files changed, 26 insertions(+), 9 deletions(-) diff --git a/IRaCIS.Core.Application/Service/Reading/ClinicalData/ClinicalAnswerService.cs b/IRaCIS.Core.Application/Service/Reading/ClinicalData/ClinicalAnswerService.cs index 3b2d051fa..9e362604b 100644 --- a/IRaCIS.Core.Application/Service/Reading/ClinicalData/ClinicalAnswerService.cs +++ b/IRaCIS.Core.Application/Service/Reading/ClinicalData/ClinicalAnswerService.cs @@ -449,6 +449,7 @@ namespace IRaCIS.Core.Application.Service IsPMConfirm = x.IsPMConfirm, SubjectCode = x.Subject.Code, ReadModuleId = x.Id, + ModuleName=x.ModuleName, }); @@ -553,7 +554,7 @@ namespace IRaCIS.Core.Application.Service /// /// [HttpPost] - public async Task> GetClinicalTableList(GetClinicalTableListInDto inDto) + public async Task<(List,object)> GetClinicalTableList(GetClinicalTableListInDto inDto) { var readModule=await _readModuleRepository.Where(x => x.Id == inDto.ReadModuleId).FirstNotNullAsync(); @@ -585,6 +586,7 @@ namespace IRaCIS.Core.Application.Service List result = new List(); clinicalDataTrialSetIds.ForEach(x => { GetClinicalTableListOutDto dto = new GetClinicalTableListOutDto(); + dto.ModuleName = readModule.ModuleName; dto.ClinicalDataSetName = confirmList.Where(y => y.ClinicalDataTrialSetId == x).Select(y => y.ClinicalDataSetName).First(); dto.QuestionList = questionList.Where(y => y.TrialClinicalId == x).OrderBy(y => y.ShowOrder).ToList(); dto.AnswerList = new List>(); @@ -602,9 +604,12 @@ namespace IRaCIS.Core.Application.Service }); result.Add(dto); }); - return result; + return (result, new + { + readModule.ModuleName, + }); - } + } /// @@ -613,9 +618,10 @@ namespace IRaCIS.Core.Application.Service /// /// [HttpPost] - public async Task> GetClinicalDateList(GetCRCBeConfirmListInDto inDto) + public async Task<(List,object)> GetClinicalDateList(GetCRCBeConfirmListInDto inDto) { - var confirmList = (await this.GetCRCConfirmList(new GetCRCConfirmListInDto() + var readModule = await _readModuleRepository.Where(x => x.Id == inDto.ReadModuleId).FirstNotNullAsync(); + var confirmList = (await this.GetCRCConfirmList(new GetCRCConfirmListInDto() { ReadModuleId = inDto.ReadModuleId, TrialId = inDto.TrialId, @@ -633,7 +639,6 @@ namespace IRaCIS.Core.Application.Service result.Add(new GetClinicalDateListOutDto() { - ClinicalDataSetName = confirmList.Where(y => y.ClinicalDataTrialSetId == x).Select(y => y.ClinicalDataSetName).First(), DateList = confirmList.Where(y => y.ClinicalDataTrialSetId == x).ToList() @@ -641,7 +646,9 @@ namespace IRaCIS.Core.Application.Service }); - return result; + return (result,new { + readModule.ModuleName, + }); } /// diff --git a/IRaCIS.Core.Application/Service/Reading/Dto/ClinicalAnswerDto.cs b/IRaCIS.Core.Application/Service/Reading/Dto/ClinicalAnswerDto.cs index f94ede42a..df49631cd 100644 --- a/IRaCIS.Core.Application/Service/Reading/Dto/ClinicalAnswerDto.cs +++ b/IRaCIS.Core.Application/Service/Reading/Dto/ClinicalAnswerDto.cs @@ -145,7 +145,12 @@ namespace IRaCIS.Core.Application.Service.Reading.Dto public class GetClinicalTableListOutDto: GetClinicalQuestionAnswerListOutDto { public string ClinicalDataSetName { get; set; } - } + + /// + /// 模块名称 + /// + public string ModuleName { get; set; } + } public class GetCRCBeConfirm: GetCRCBeConfirmListOutDto @@ -210,7 +215,12 @@ namespace IRaCIS.Core.Application.Service.Reading.Dto public Guid SubjectId { get; set; } public Guid ReadModuleId { get; set; } - public bool IsPMConfirm { get; set; } + /// + /// 模块名称 + /// + public string ModuleName { get; set; } + + public bool IsPMConfirm { get; set; } public ReadingSetType ReadingSetType { get; set; }