From 132ff3b6b6777feeb5f381afd716efd1ebbb5ab2 Mon Sep 17 00:00:00 2001
From: wxd <123@qq.com>
Date: Sun, 28 Apr 2024 17:28:14 +0800
Subject: [PATCH 1/3] =?UTF-8?q?=E5=8D=95=E4=BD=8D=E6=8A=A5=E5=91=8A?=
 =?UTF-8?q?=E3=80=81=E6=80=BB=E6=A3=80=E4=BD=93=E6=A3=80=E7=BB=93=E8=AE=BA?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
 ...datePatientRegisterSummarySuggestionDto.cs |  3 +--
 .../LisRequests/LisRequestManager.cs          | 20 +++++++++----------
 .../CustomerOrgReportManager.cs               | 14 ++++++-------
 3 files changed, 18 insertions(+), 19 deletions(-)
diff --git a/src/Shentun.Peis.Application.Contracts/PatientRegisters/UpdatePatientRegisterSummarySuggestionDto.cs b/src/Shentun.Peis.Application.Contracts/PatientRegisters/UpdatePatientRegisterSummarySuggestionDto.cs
index aed97cd..8d2140a 100644
--- a/src/Shentun.Peis.Application.Contracts/PatientRegisters/UpdatePatientRegisterSummarySuggestionDto.cs
+++ b/src/Shentun.Peis.Application.Contracts/PatientRegisters/UpdatePatientRegisterSummarySuggestionDto.cs
@@ -26,8 +26,7 @@ namespace Shentun.Peis.PatientRegisters
         /// 
         /// 体检结论ID
         /// 
-        [Required(ErrorMessage ="体检结论不能为空")]
-        public Guid MedicalConclusionId { get; set; }
+        public Guid? MedicalConclusionId { get; set; }
 
         public List SumSummarys { get; set; }
         public List SumSuggestions { get; set; }
diff --git a/src/Shentun.Peis.Domain/LisRequests/LisRequestManager.cs b/src/Shentun.Peis.Domain/LisRequests/LisRequestManager.cs
index 1a65f33..294d7d2 100644
--- a/src/Shentun.Peis.Domain/LisRequests/LisRequestManager.cs
+++ b/src/Shentun.Peis.Domain/LisRequests/LisRequestManager.cs
@@ -96,17 +96,17 @@ namespace Shentun.Peis.LisRequests
                 }
             }
             //未设置的申请单设置到相同分组的已有申请单
-            var noRequestCheckAsbitems = registerCheckAsbitems.Where(o=>o.LisRequestId == null || o.LisRequestId == Guid.Empty).ToList();
-            foreach(var registerCheckAsbitem in noRequestCheckAsbitems)
+            var noRequestCheckAsbitems = registerCheckAsbitems.Where(o => o.LisRequestId == null || o.LisRequestId == Guid.Empty).ToList();
+            foreach (var registerCheckAsbitem in noRequestCheckAsbitems)
             {
                 var registerCheckAsbitemLis = registerCheckAsbitemLisList.Where(o => o.RegisterCheckAsbitemId == registerCheckAsbitem.Id).SingleOrDefault();
                 if (registerCheckAsbitemLis == null)
                 {
                     continue;
                 }
-                var haveRegisterCheckAsbitemLis =  registerCheckAsbitemLisList.Where(o => o.SampleGroupId == registerCheckAsbitemLis.SampleGroupId
+                var haveRegisterCheckAsbitemLis = registerCheckAsbitemLisList.Where(o => o.SampleGroupId == registerCheckAsbitemLis.SampleGroupId
                 && o.LisRequestId != null && o.LisRequestId != Guid.Empty).SingleOrDefault();
-                if( haveRegisterCheckAsbitemLis != null)
+                if (haveRegisterCheckAsbitemLis != null)
                 {
                     registerCheckAsbitem.LisRequestId = haveRegisterCheckAsbitemLis.LisRequestId;
                     updateRegisterCheckAsbitems.Add(registerCheckAsbitem);
@@ -117,7 +117,7 @@ namespace Shentun.Peis.LisRequests
             var noRequestLisList = registerCheckAsbitemLisList.Where(o => noRequestCheckAsbitems.Select(o => o.Id).Contains(o.RegisterCheckAsbitemId)).ToList();
             var sampleGroupids = noRequestLisList.Select(o => o.SampleGroupId).Distinct();
             createLisRequests = new List();
-            foreach ( var sampleGroupid in sampleGroupids)
+            foreach (var sampleGroupid in sampleGroupids)
             {
                 var sampleGroup = sampleGroups.Where(o => o.Id == sampleGroupid).Single();
                 //var guid = GuidGenerator.Create();
@@ -132,7 +132,7 @@ namespace Shentun.Peis.LisRequests
                 createLisRequests.Add(lisRequest);
                 foreach (var requestLis in noRequestLisList)
                 {
-                    if(requestLis.SampleGroupId ==  sampleGroupid)
+                    if (requestLis.SampleGroupId == sampleGroupid)
                     {
                         requestLis.LisRequestId = lisRequest.Id;
                         var registerCheckAsbitem = noRequestCheckAsbitems.Where(o => o.Id == requestLis.RegisterCheckAsbitemId).Single();
@@ -142,7 +142,7 @@ namespace Shentun.Peis.LisRequests
                 }
             }
 
-           
+
         }
 
 
@@ -261,7 +261,7 @@ namespace Shentun.Peis.LisRequests
         public async Task SendThirdLisRequest(Guid id)
         {
             var thirdInterfaces = (await _thirdInterfaceRepository.GetListAsync(o => o.ThirdInterfaceType == ThirdInterfaceTypeFlag.ChargeRequest))
-                                   .OrderBy(o=>o.DisplayOrder).ToList();
+                                   .OrderBy(o => o.DisplayOrder).ToList();
             foreach (var thirdInterface in thirdInterfaces)
             {
                 var lisRequestPluginsInput = new LisRequestPluginsInput()
@@ -275,7 +275,7 @@ namespace Shentun.Peis.LisRequests
                 var config = configurationBuilder.Build();
                 var assemblyName = config.GetSection("Interface").GetSection("AssemblyName").Value;
                 var className = config.GetSection("Interface").GetSection("ClassName").Value;
-                object[] objects = [lisRequestPluginsInput];
+                object[] objects = new object[] { lisRequestPluginsInput };
                 var LisRequestPluginsOut = await InvokeAsync(assemblyName, className, parmValue, "SendRequest", objects);
             }
         }
@@ -408,7 +408,7 @@ namespace Shentun.Peis.LisRequests
         }
 
         private class RegisterCheckAsbitemLis
-        { 
+        {
             public Guid RegisterCheckAsbitemId { get; set; }
             public Guid SampleGroupId { get; set; }
             public Guid? LisRequestId { get; set; }
diff --git a/src/Shentun.Peis.Domain/ReportTemplates/CustomerOrgReportManager.cs b/src/Shentun.Peis.Domain/ReportTemplates/CustomerOrgReportManager.cs
index dc67120..b799fee 100644
--- a/src/Shentun.Peis.Domain/ReportTemplates/CustomerOrgReportManager.cs
+++ b/src/Shentun.Peis.Domain/ReportTemplates/CustomerOrgReportManager.cs
@@ -821,18 +821,18 @@ namespace Shentun.Peis.ReportTemplates
             Header header = template.Headers.Odd;
             // Insert Paragraph in header
             Paragraph paragraph = header.InsertParagraph();
-            Xceed.Document.NET.Image logo = template.AddImage(DirectoryName + @"\CustomerOrgTemplate\header.jpg");
+            Xceed.Document.NET.Image logo = template.AddImage(DirectoryName + @"\CustomerOrgTemplate\logo.jpg");
             var pic = logo.CreatePicture();
-            pic.Width = 41.59f;
-            pic.Height = 30.3f;
+            pic.Width = 40f;
+            pic.Height = 40f;
             paragraph.AppendPicture(pic);
             paragraph.Append("\t\t\t\t健康体检中心");
 
             template.AddFooters();
             Footer footer = template.Footers.Odd;
             // Insert Paragraph in header
-            Paragraph paragraph1 = footer.InsertParagraph();
-            paragraph1.Append("File Format Develoer Guide");
+            //Paragraph paragraph1 = footer.InsertParagraph();
+            //paragraph1.Append("File Format Develoer Guide");
             #region 封面
 
             template.ReplaceText(new StringReplaceTextOptions
@@ -1132,9 +1132,9 @@ namespace Shentun.Peis.ReportTemplates
             List rows = p1Titletable.Rows;
 
             Row row0 = rows[0];
-            row0.Height = 65f;
+            row0.Height = 50f;
             row0.Cells[0].Width = 50f;
-            Xceed.Document.NET.Image logo = document.AddImage(DirectoryName + @"\CustomerOrgTemplate\logo_template.jpg");
+            Xceed.Document.NET.Image logo = document.AddImage(DirectoryName + @"\CustomerOrgTemplate\logo.jpg");
             Formatting p1TitleFormatting = new Formatting();
             p1TitleFormatting.FontFamily = new Xceed.Document.NET.Font("宋体");
             p1TitleFormatting.FontColor = Color.FromArgb(0, 128, 0);
From a2579f767910fb086de5ea7f105fdfe473ed8fc6 Mon Sep 17 00:00:00 2001
From: wxd <123@qq.com>
Date: Sun, 28 Apr 2024 17:52:35 +0800
Subject: [PATCH 2/3] =?UTF-8?q?=E5=8D=95=E4=BD=8D=E6=8A=A5=E8=A1=A8?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
 .../ReportTemplates/CustomerOrgReportManager.cs          | 9 ++++++---
 1 file changed, 6 insertions(+), 3 deletions(-)
diff --git a/src/Shentun.Peis.Domain/ReportTemplates/CustomerOrgReportManager.cs b/src/Shentun.Peis.Domain/ReportTemplates/CustomerOrgReportManager.cs
index b799fee..c93a051 100644
--- a/src/Shentun.Peis.Domain/ReportTemplates/CustomerOrgReportManager.cs
+++ b/src/Shentun.Peis.Domain/ReportTemplates/CustomerOrgReportManager.cs
@@ -1132,13 +1132,16 @@ namespace Shentun.Peis.ReportTemplates
             List rows = p1Titletable.Rows;
 
             Row row0 = rows[0];
-            row0.Height = 50f;
+            row0.Height = 65f;
             row0.Cells[0].Width = 50f;
-            Xceed.Document.NET.Image logo = document.AddImage(DirectoryName + @"\CustomerOrgTemplate\logo.jpg");
+            Xceed.Document.NET.Image logo = document.AddImage(DirectoryName + @"\CustomerOrgTemplate\logo_template.jpg");
             Formatting p1TitleFormatting = new Formatting();
             p1TitleFormatting.FontFamily = new Xceed.Document.NET.Font("宋体");
             p1TitleFormatting.FontColor = Color.FromArgb(0, 128, 0);
-            row0.Cells[0].Paragraphs[0].AppendPicture(logo.CreatePicture());
+            var pic = logo.CreatePicture();
+            pic.Width = 65f;
+            pic.Height = 65f;
+            row0.Cells[0].Paragraphs[0].AppendPicture(pic);
             row0.Cells[0].VerticalAlignment = VerticalAlignment.Center;
             row0.Cells[1].Width = document.PageWidth - document.MarginLeft - document.MarginRight - 30f;
             row0.Cells[1].Paragraphs[0].Append("团体体检健康检查统计报告", p1TitleFormatting).FontSize(22).Alignment = Alignment.center;
From ae211d938648b647ef7aa52cee50da12e3e8dcb5 Mon Sep 17 00:00:00 2001
From: wxd <123@qq.com>
Date: Sun, 28 Apr 2024 19:31:55 +0800
Subject: [PATCH 3/3] =?UTF-8?q?=E6=8A=A5=E8=A1=A8?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
 .../ReportFormatTemplates/ReportFormatTemplateAppService.cs      | 1 +
 1 file changed, 1 insertion(+)
diff --git a/src/Shentun.Peis.Application/ReportFormatTemplates/ReportFormatTemplateAppService.cs b/src/Shentun.Peis.Application/ReportFormatTemplates/ReportFormatTemplateAppService.cs
index 5bf2de9..7458a6e 100644
--- a/src/Shentun.Peis.Application/ReportFormatTemplates/ReportFormatTemplateAppService.cs
+++ b/src/Shentun.Peis.Application/ReportFormatTemplates/ReportFormatTemplateAppService.cs
@@ -215,6 +215,7 @@ namespace Shentun.Peis.ReportFormatTemplates
         /// 
         /// 
         /// 
+        [HttpPost("api/app/ReportFormatTemplate/Update")]
         public override async Task UpdateAsync(string id, UpdateReportFormatTemplateDto input)
         {
             var entity = await Repository.GetAsync(id);