From fec79d27b9b90b4bbbbfa7d0d8b3d57a33cbdc6f Mon Sep 17 00:00:00 2001 From: wxd <123@qq.com> Date: Mon, 23 Mar 2026 09:32:55 +0800 Subject: [PATCH] =?UTF-8?q?=E9=98=B3=E6=80=A7=E7=BB=93=E6=9E=9C=E6=8A=A5?= =?UTF-8?q?=E8=A1=A8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../CustomerReports/CustomerReportAppService.cs | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/Shentun.Peis.Application/CustomerReports/CustomerReportAppService.cs b/src/Shentun.Peis.Application/CustomerReports/CustomerReportAppService.cs index e2c1547f..c98f9a69 100644 --- a/src/Shentun.Peis.Application/CustomerReports/CustomerReportAppService.cs +++ b/src/Shentun.Peis.Application/CustomerReports/CustomerReportAppService.cs @@ -1116,8 +1116,8 @@ namespace Shentun.Peis.CustomerReports var sumCount = queryGroup.Count(); - resultListDto.MaleCount = queryGroup.Count(c => c.Key.SexId == 'M'); - resultListDto.FemaleCount = queryGroup.Count(c => c.Key.SexId == 'F'); + resultListDto.RegisterMaleCount = queryGroup.Count(c => c.Key.SexId == 'M'); + resultListDto.RegisterFemaleCount = queryGroup.Count(c => c.Key.SexId == 'F'); List patientRegisterList = new List(); @@ -1234,8 +1234,8 @@ namespace Shentun.Peis.CustomerReports resultListDto.StartDate = DataHelper.ConversionDateShortToString(input.CustomerOrgs.Where(m => !string.IsNullOrWhiteSpace(m.StartDate)).Select(s => Convert.ToDateTime(s.StartDate)).Min()); resultListDto.EndDate = DataHelper.ConversionDateShortToString(input.CustomerOrgs.Where(m => !string.IsNullOrWhiteSpace(m.EndDate)).Select(s => Convert.ToDateTime(s.EndDate)).Max()); - //resultListDto.MaleCount = patientRegisters.Count(c => c.SexId == 'M'); - //resultListDto.FemaleCount = patientRegisters.Count(c => c.SexId == 'F'); + resultListDto.MaleCount = patientRegisterList.Distinct().Count(c => c.SexId == 'M'); + resultListDto.FemaleCount = patientRegisterList.Distinct().Count(c => c.SexId == 'F'); resultListDto.Details = entListDto; return resultListDto;