From 14bab2d291b201db27aba7362f66583cd7a2d4c2 Mon Sep 17 00:00:00 2001 From: wxd <123@qq.com> Date: Mon, 8 Apr 2024 10:20:19 +0800 Subject: [PATCH] =?UTF-8?q?=E5=AE=A2=E6=88=B7=E6=8A=A5=E8=A1=A8=E4=B8=B4?= =?UTF-8?q?=E6=97=B6=E4=BF=9D=E5=AD=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- ...tPhysicalExaminationReportExportWordDto.cs | 253 ++++++++++++++++++ ...alExaminationReportExportWordRequestDto.cs | 16 ++ .../CustomerReportAppService.cs | 51 ++++ 3 files changed, 320 insertions(+) create mode 100644 src/Shentun.Peis.Application.Contracts/CustomerReports/GetUnitPhysicalExaminationReportExportWordDto.cs create mode 100644 src/Shentun.Peis.Application.Contracts/CustomerReports/GetUnitPhysicalExaminationReportExportWordRequestDto.cs diff --git a/src/Shentun.Peis.Application.Contracts/CustomerReports/GetUnitPhysicalExaminationReportExportWordDto.cs b/src/Shentun.Peis.Application.Contracts/CustomerReports/GetUnitPhysicalExaminationReportExportWordDto.cs new file mode 100644 index 0000000..4c85ea7 --- /dev/null +++ b/src/Shentun.Peis.Application.Contracts/CustomerReports/GetUnitPhysicalExaminationReportExportWordDto.cs @@ -0,0 +1,253 @@ +using System; +using System.Collections.Generic; +using System.Text; + +namespace Shentun.Peis.CustomerReports +{ + public class GetUnitPhysicalExaminationReportExportWordDto + { + /// + /// 体检年度 + /// + public string MedicalYear { get; set; } + + /// + /// 单位名称 + /// + public string CustomerOrgName { get; set; } + + /// + /// 体检次数 + /// + public int MedicalTimes { get; set; } + + /// + /// 体检开始月份 格式:2009年09月 + /// + public string MedicalStartDate { get; set; } + + /// + /// 体检结束月份 格式:2009年09月 + /// + public string MedicalEndDate { get; set; } + + /// + /// 制表日期 格式:2009年09月09日 + /// + public string TabulationDate { get; set; } + + + /// + /// 打印日期 格式:2009年09月09日 + /// + public string PrintDate { get; set; } + + + /// + /// 参加人员构成情况 第一部分 + /// + public GetUnitPhysicalExaminationReportExportWord_InspectionPersonnel InspectionPersonnel { get; set; } + + /// + /// 体检项目得参检情况 第二部分 + /// + public List MedicalItemExamineSituations { get; set; } + + /// + /// 全体员工体检结果汇总 第三部分 + /// + public List MedicalResultSummarys { get; set; } + + + + } + + /// + /// 参加人员构成情况 + /// + public class GetUnitPhysicalExaminationReportExportWord_InspectionPersonnel + { + /// + /// 男性登记人数 + /// + public int MaleRegisterNumber { get; set; } + + /// + /// 女性登记人数 + /// + public int FemaleRegisterNumber { get; set; } + + /// + /// 其他登记人数 + /// + public int OtherRegisterNumber { get; set; } + + /// + /// 合计登记人数 + /// + public int SumRegisterNumber { get; set; } + + /// + /// 登记明细 + /// + public InspectionPersonnel_Detail RegisterDetail { get; set; } + + /// + /// 实检明细 + /// + public InspectionPersonnel_Detail CheckedDetail { get; set; } + + /// + /// 未检明细 + /// + public InspectionPersonnel_Detail UnCheckedDetail { get; set; } + } + + /// + /// 检查明细 + /// + public class InspectionPersonnel_Detail + { + /// + /// 男性人数 + /// + public int MaleNumber { get; set; } + + /// + /// 女性人数 + /// + public int FemaleNumber { get; set; } + + /// + /// 其他人数 + /// + public int OtherNumber { get; set; } + + /// + /// 合计人数 + /// + public int TotalNumber { get; set; } + + /// + /// 男性比例 + /// + public string MaleRatio { get; set; } + + /// + /// 女性比例 + /// + public string FemaleRatio { get; set; } + + /// + /// 男性参检比例 + /// + public string MaleExamineRatio { get; set; } + + /// + /// 女性参检比例 + /// + public string FemaleExamineRatio { get; set; } + + + /// + /// 平均参检比例 + /// + public string AverageExamineRatio { get; set; } + } + + + /// + /// 体检项目得参检情况 + /// + public class GetUnitPhysicalExaminationReportExportWord_MedicalItemExamineSituation + { + /// + /// 科室 + /// + public string ItemTypeName { get; set; } + + /// + /// 组合项目名称 + /// + public string AsbitemName { get; set; } + + /// + /// 男性该项目参检人数 + /// + public int MaleAsbitemCheckNumber { get; set; } + + /// + /// 女性该项目参检人数 + /// + public int FemaleAsbitemCheckNumber { get; set; } + + /// + /// 合计该项目参检人数 + /// + public int TotalAsbitemCheckNumber { get; set; } + + /// + /// 男性总体参检人数 所有项目 + /// + public int MaleSumCheckNumber { get; set; } + + /// + /// 女性总体参检人数 所有项目 + /// + public int FemaleSumCheckNumber { get; set; } + + /// + /// 合计总体参检人数 所有项目 + /// + public int TotalSumCheckNumber { get; set; } + + + /// + /// 男性该项目参检比例 + /// + public int MaleAsbitemCheckRatio { get; set; } + + /// + /// 女性该项目参检比例 + /// + public int FemaleAsbitemCheckRatio { get; set; } + + /// + /// 合计该项目参检比例 + /// + public int TotalAsbitemCheckRatio { get; set; } + + + } + + /// + /// 全体员工体检结果汇总 统计已总检的名单 + /// + public class GetUnitPhysicalExaminationReportExportWord_MedicalResultSummary + { + /// + /// 档案号 + /// + public string PatientNo { get; set; } + + /// + /// 姓名 + /// + public string PatientName { get; set; } + + /// + /// 性别 + /// + public string SexName { get; set; } + + /// + /// 年龄 + /// + public string Age { get; set; } + + /// + /// 体检结果 + /// + public string MedicalResult { get; set; } + } +} diff --git a/src/Shentun.Peis.Application.Contracts/CustomerReports/GetUnitPhysicalExaminationReportExportWordRequestDto.cs b/src/Shentun.Peis.Application.Contracts/CustomerReports/GetUnitPhysicalExaminationReportExportWordRequestDto.cs new file mode 100644 index 0000000..7a59cdd --- /dev/null +++ b/src/Shentun.Peis.Application.Contracts/CustomerReports/GetUnitPhysicalExaminationReportExportWordRequestDto.cs @@ -0,0 +1,16 @@ +using Shentun.Peis.PeisReports; +using System; +using System.Collections.Generic; +using System.Text; + +namespace Shentun.Peis.CustomerReports +{ + + public class GetUnitPhysicalExaminationReportExportWordRequestDto + { + /// + /// 单位相关 + /// + public List CustomerOrgs { get; set; } = new List(); + } +} diff --git a/src/Shentun.Peis.Application/CustomerReports/CustomerReportAppService.cs b/src/Shentun.Peis.Application/CustomerReports/CustomerReportAppService.cs index 428d2d1..4b26405 100644 --- a/src/Shentun.Peis.Application/CustomerReports/CustomerReportAppService.cs +++ b/src/Shentun.Peis.Application/CustomerReports/CustomerReportAppService.cs @@ -923,6 +923,57 @@ namespace Shentun.Peis.CustomerReports } + + ///// + ///// 单位体检报表 导出word + ///// + ///// + ///// + //[HttpPost("api/customerreport/getunitphysicalexaminationreportreduce")] + //public async Task GetUnitPhysicalExaminationReportExportWordAsync(GetUnitPhysicalExaminationReportExportWordRequestDto input) + //{ + + // if (input.CustomerOrgs.Count != 1) + // { + // throw new UserFriendlyException("必须选择并且只能选择一个单位"); + // } + // //人员阳性结果清单 + // var PatientRegisterPositiveReports = await GetPatientRegisterPositiveReportAsync(new GetPatientRegisterPositiveReportRequestDto { CustomerOrgs = input.CustomerOrgs }); + + // //阳性结果包含人员清单 精简模式 + // var PositivePatientRegisterReportReduces = await GetPositivePatientRegisterReportReduceAsync(new GetPositivePatientRegisterReportRequestDto { CustomerOrgs = input.CustomerOrgs }); + + // //疾病人数统计 + // var DiseaseCountStatisticsReports = await GetDiseaseCountStatisticsReportAsync(new GetDiseaseCountStatisticsReportRequestDto { CustomerOrgs = input.CustomerOrgs }); + + // var query = from a in await _customerOrgRegisterRepository.GetQueryableAsync() + // join b in await _customerOrgRepository.GetQueryableAsync() on a.CustomerOrgId equals b.Id into bb + // from ab in bb.DefaultIfEmpty() + // select new { a, ab }; + + // if (input.CustomerOrgs.Any()) + // { + // query = query.Where(m => input.CustomerOrgs.Where(m => m.CustomerOrgRegisterId != null && m.CustomerOrgRegisterId != Guid.Empty).Select(s => s.CustomerOrgRegisterId).Contains(m.a.Id)); + // } + + // var entlist = new GetUnitPhysicalExaminationReportReduceDto + // { + // CustomerOrgs = query.Select(s => new GetUnitPhysicalExaminationStandardReport_CustomerOrg + // { + // BeginTime = s.a.BeginTime.ToString(), + // EndTime = s.a.EndTime != null ? s.a.EndTime.ToString() : "", + // CustomerOrgName = s.ab != null ? s.ab.DisplayName : "", + // MedicalTimes = s.a.MedicalTimes + // }).ToList(), + // DiseaseCountStatisticsReports = DiseaseCountStatisticsReports, + // PatientRegisterPositiveReports = PatientRegisterPositiveReports, + // PositivePatientRegisterReportReduces = PositivePatientRegisterReportReduces + // }; + + // return entlist; + //} + + ///// ///// 组合项目具体结果统计 组合项目可以多选 但是必选的 /////