From 3d382635ccb88713f09c0ed9d3dfb16aff2f0c91 Mon Sep 17 00:00:00 2001 From: he <109787524@qq.com> Date: Wed, 25 Sep 2024 10:34:20 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BB=A3=E7=A0=81=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../ReadingCalculate/OCTCalculateService.cs | 44 +++++++++++++++++++ .../_IRaCIS/_Config/_StaticData.cs | 4 ++ 2 files changed, 48 insertions(+) diff --git a/IRaCIS.Core.Application/Service/ReadingCalculate/OCTCalculateService.cs b/IRaCIS.Core.Application/Service/ReadingCalculate/OCTCalculateService.cs index d8eb8c41d..414e7cb28 100644 --- a/IRaCIS.Core.Application/Service/ReadingCalculate/OCTCalculateService.cs +++ b/IRaCIS.Core.Application/Service/ReadingCalculate/OCTCalculateService.cs @@ -22,6 +22,7 @@ namespace IRaCIS.Core.Application.Service.ReadingCalculate IRepository _subjectVisitRepository, IRepository _tumorAssessmentRepository, IGeneralCalculateService _generalCalculateService, + IVisitTaskHelpeService _visitTaskHelpeService, IRepository _readingTaskQuestionAnswerRepository, ILogger _logger) : BaseService, ICriterionCalculateService { @@ -433,6 +434,49 @@ namespace IRaCIS.Core.Application.Service.ReadingCalculate }; } + /// + /// 获取OCT-FCT模板 + /// + /// + /// + [HttpPost] + public async Task GetOCTFCTTemplate(GetExportTemplateInDto inDto) + { + var taskinfo = await _visitTaskRepository.Where(x => x.Id == inDto.VisitTaskId).Include(x => x.Subject).FirstNotNullAsync(); + var values = new + { + SubjectID = taskinfo.BlindSubjectCode.IsNullOrEmpty() ? taskinfo.Subject.Code : taskinfo.BlindSubjectCode, + TaskBlindName = taskinfo.TaskBlindName, + }; + return await _visitTaskHelpeService.ExportTemplateAsync(new IRaCIS.Application.Contracts.ExportTemplateAsyncDto() + { + ExportFileName = "OCT_FCT_Template", + TemplateCode = StaticData.Export.OCT_FCT_Template, + Data = values + }); + } + + /// + /// 获取OCT-脂质角度模板 + /// + /// + /// + [HttpPost] + public async Task GetOCTLipidAngleTemplate(GetExportTemplateInDto inDto) + { + var taskinfo = await _visitTaskRepository.Where(x => x.Id == inDto.VisitTaskId).Include(x => x.Subject).FirstNotNullAsync(); + var values = new + { + SubjectID = taskinfo.BlindSubjectCode.IsNullOrEmpty() ? taskinfo.Subject.Code : taskinfo.BlindSubjectCode, + TaskBlindName = taskinfo.TaskBlindName, + }; + return await _visitTaskHelpeService.ExportTemplateAsync(new IRaCIS.Application.Contracts.ExportTemplateAsyncDto() + { + ExportFileName = "OCT_LipidAngle_Template", + TemplateCode = StaticData.Export.OCT_LipidAngle_Template, + Data = values + }); + } /// diff --git a/IRaCIS.Core.Infrastructure/_IRaCIS/_Config/_StaticData.cs b/IRaCIS.Core.Infrastructure/_IRaCIS/_Config/_StaticData.cs index 3472cc21d..0d06b9e5c 100644 --- a/IRaCIS.Core.Infrastructure/_IRaCIS/_Config/_StaticData.cs +++ b/IRaCIS.Core.Infrastructure/_IRaCIS/_Config/_StaticData.cs @@ -276,6 +276,10 @@ public static class StaticData public const string IVUSTheMeasuredValueOfEachMatchedFragment = "IVUS_TheMeasuredValueOfEachMatchedFragment"; + public const string OCT_FCT_Template = "OCT_FCT_Template"; + + public const string OCT_LipidAngle_Template = "OCT_LipidAngle_Template"; + }