From 493d604cbdfdb6ade4c3048ef3c0fdd4c5434e5b Mon Sep 17 00:00:00 2001 From: wanghaomei Date: Mon, 27 Mar 2023 16:08:39 +0800 Subject: [PATCH 1/6] =?UTF-8?q?=E9=A2=84=E8=A7=88pdf=E6=97=A5=E5=BF=97?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Service/BookingOrder/BookingOrderService.cs | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Myshipping.Application/Service/BookingOrder/BookingOrderService.cs b/Myshipping.Application/Service/BookingOrder/BookingOrderService.cs index ecc12c1b..d7450132 100644 --- a/Myshipping.Application/Service/BookingOrder/BookingOrderService.cs +++ b/Myshipping.Application/Service/BookingOrder/BookingOrderService.cs @@ -2527,11 +2527,13 @@ namespace Myshipping.Application var fileFullName = Path.Combine(fileFullPath, fn); if (File.Exists(fileFullName)) { + _logger.LogDebug($"预览pdf文件:{fileFullName}"); var readMem = new ReadOnlyMemory(File.ReadAllBytes(fileFullName)); _httpContextAccessor.HttpContext.Response.BodyWriter.WriteAsync(readMem); } else { + _logger.LogDebug($"未找到预览pdf文件:{fileFullName}"); _httpContextAccessor.HttpContext.Response.StatusCode = 404; } } From e6cc57f3ac6c72e6013387d931b96019d634122e Mon Sep 17 00:00:00 2001 From: wanghaomei Date: Mon, 27 Mar 2023 16:15:02 +0800 Subject: [PATCH 2/6] =?UTF-8?q?=E9=A2=84=E8=A7=88pdf=E6=97=A5=E5=BF=97?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Service/BookingOrder/BookingOrderService.cs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Myshipping.Application/Service/BookingOrder/BookingOrderService.cs b/Myshipping.Application/Service/BookingOrder/BookingOrderService.cs index d7450132..322bbf1b 100644 --- a/Myshipping.Application/Service/BookingOrder/BookingOrderService.cs +++ b/Myshipping.Application/Service/BookingOrder/BookingOrderService.cs @@ -2527,13 +2527,13 @@ namespace Myshipping.Application var fileFullName = Path.Combine(fileFullPath, fn); if (File.Exists(fileFullName)) { - _logger.LogDebug($"预览pdf文件:{fileFullName}"); + _logger.LogInformation($"预览pdf文件:{fileFullName}"); var readMem = new ReadOnlyMemory(File.ReadAllBytes(fileFullName)); _httpContextAccessor.HttpContext.Response.BodyWriter.WriteAsync(readMem); } else { - _logger.LogDebug($"未找到预览pdf文件:{fileFullName}"); + _logger.LogInformation($"未找到预览pdf文件:{fileFullName}"); _httpContextAccessor.HttpContext.Response.StatusCode = 404; } } From 17eb420f9271c0f405322ed990a50c34a94950d0 Mon Sep 17 00:00:00 2001 From: jianghaiqing Date: Mon, 27 Mar 2023 16:58:03 +0800 Subject: [PATCH 3/6] =?UTF-8?q?=E4=BF=AE=E6=94=B9EDI=20PIL=E5=A2=9E?= =?UTF-8?q?=E5=8A=A0=E5=95=86=E5=93=81=E4=BB=A3=E7=A0=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Myshipping.Application/EDI/Dtos/MsOpSeaeEDIBaseModel.cs | 5 +++++ Myshipping.Application/EDI/PILEdiHelper.cs | 4 +++- .../Service/BookingOrder/Dto/BookingEDIMapper.cs | 3 ++- 3 files changed, 10 insertions(+), 2 deletions(-) diff --git a/Myshipping.Application/EDI/Dtos/MsOpSeaeEDIBaseModel.cs b/Myshipping.Application/EDI/Dtos/MsOpSeaeEDIBaseModel.cs index a4048e51..17b6de9a 100644 --- a/Myshipping.Application/EDI/Dtos/MsOpSeaeEDIBaseModel.cs +++ b/Myshipping.Application/EDI/Dtos/MsOpSeaeEDIBaseModel.cs @@ -585,5 +585,10 @@ namespace Myshipping.Application /// 运输条款EDI代码 M /// public string SERVICEEDICODE { get; set; } + + /// + /// 商品代码 + /// + public string GOODSCODE { get; set; } } } diff --git a/Myshipping.Application/EDI/PILEdiHelper.cs b/Myshipping.Application/EDI/PILEdiHelper.cs index 548bf5de..11239890 100644 --- a/Myshipping.Application/EDI/PILEdiHelper.cs +++ b/Myshipping.Application/EDI/PILEdiHelper.cs @@ -1479,7 +1479,9 @@ namespace Myshipping.Application.EDI.PIL tempstr += GetSpaceStr((ctn.CBM * 1000).ToString("0.###"), 10, "0");//11 //Cargo Nett Measurement//C//9(7)v999//61 //70 //Mandatory, except for Empties tempstr += GetSpaceStr(bill.GOODSNAME, 48);//12 //Commodity Name//O//X(48)//71 //118 // //tempstr += GetSpaceStr(GetGOODEDICode(bill.GOODSNAME), 4);//13 //webcsm Commodity Code//O//X(4)//119 //122 //webCSM Standard Commodity Code - tempstr += GetSpaceStr("", 4);//13 //webcsm Commodity Code//O//X(4)//119 //122 //webCSM Standard Commodity Code + //2023-03-27 跟韩工确认这里加入商品代码 + //tempstr += GetSpaceStr("", 4);//13 //webcsm Commodity Code//O//X(4)//119 //122 //webCSM Standard Commodity Code + tempstr += GetSpaceStr(bill.GOODSCODE, 4);//13 //webcsm Commodity Code//O//X(4)//119 //122 //webCSM Standard Commodity Code tempstr += GetSpaceStr(ctn.CTNALLCODE, 4);//14 //webcsm Package Code//M//X(4)//123 //126 //eg 20GP, 40GP etc. tempstr += "KGM";//15 //UOM Weight//M//X(3)//127 //129 //Default to METRIC = KGM tempstr += "MTQ";//16 //UOM Measurement//M//X(3)//130 //132 //Default to METRIC = MTQ diff --git a/Myshipping.Application/Service/BookingOrder/Dto/BookingEDIMapper.cs b/Myshipping.Application/Service/BookingOrder/Dto/BookingEDIMapper.cs index e4cd175e..af7e9ead 100644 --- a/Myshipping.Application/Service/BookingOrder/Dto/BookingEDIMapper.cs +++ b/Myshipping.Application/Service/BookingOrder/Dto/BookingEDIMapper.cs @@ -67,7 +67,8 @@ namespace Myshipping.Application .Map(dest => dest.PLACEDELIVERYID, src => src.PLACEDELIVERYID) .Map(dest => dest.PLACEDELIVERY, src => src.PLACEDELIVERY) .Map(dest => dest.CARRIER, src => src.CARRIER) - .Map(dest => dest.CARRIERID, src => src.CARRIERID); + .Map(dest => dest.CARRIERID, src => src.CARRIERID) + .Map(dest => dest.GOODSCODE, src => src.GOODSCODE); config.ForType() From 464af5d99e31a6a83167bfaba1edf9f77e49614a Mon Sep 17 00:00:00 2001 From: wanghaomei Date: Mon, 27 Mar 2023 17:59:43 +0800 Subject: [PATCH 4/6] =?UTF-8?q?=E6=89=93=E5=8D=B0=E9=A2=84=E8=A7=88?= =?UTF-8?q?=E4=B8=8D=E8=83=BD=E4=B8=8B=E8=BD=BD=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Service/BookingOrder/BookingOrderService.cs | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/Myshipping.Application/Service/BookingOrder/BookingOrderService.cs b/Myshipping.Application/Service/BookingOrder/BookingOrderService.cs index 322bbf1b..f4f2965f 100644 --- a/Myshipping.Application/Service/BookingOrder/BookingOrderService.cs +++ b/Myshipping.Application/Service/BookingOrder/BookingOrderService.cs @@ -2247,7 +2247,7 @@ namespace Myshipping.Application - fileName = $"{order.MBLNO}_{DateTime.Now.Ticks}";//名称 + fileName = $"{order.MBLNO}_{DateTime.Now.Ticks}{fileType}";//名称 var opt = App.GetOptions().Path; var serverpath = Path.Combine(App.WebHostEnvironment.WebRootPath, opt);//服务器路径 if (!Directory.Exists(serverpath)) @@ -2528,8 +2528,14 @@ namespace Myshipping.Application if (File.Exists(fileFullName)) { _logger.LogInformation($"预览pdf文件:{fileFullName}"); - var readMem = new ReadOnlyMemory(File.ReadAllBytes(fileFullName)); - _httpContextAccessor.HttpContext.Response.BodyWriter.WriteAsync(readMem); + + var sysConfig = _cache.GetAllSysConfig().Result; + var viewUrl = sysConfig.FirstOrDefault(x => x.Code == "booking_print_view_pdf_url"); + + //var readMem = new ReadOnlyMemory(File.ReadAllBytes(fileFullName)); + //_httpContextAccessor.HttpContext.Response.BodyWriter.WriteAsync(readMem); + _httpContextAccessor.HttpContext.Response.StatusCode = 302; + _httpContextAccessor.HttpContext.Response.Headers["Location"] = $"{viewUrl.Value}{fn}"; } else { From ec467e88631f76fca6530d3796ecdaa314e4d12d Mon Sep 17 00:00:00 2001 From: jianghaiqing Date: Tue, 28 Mar 2023 09:44:05 +0800 Subject: [PATCH 5/6] =?UTF-8?q?=E4=BF=AE=E6=94=B9EDI=20PIL=E7=9A=84?= =?UTF-8?q?=E6=88=AA=E5=8D=95=E6=96=87=E4=BB=B6=E5=90=8D=E5=8E=BB=E6=8E=89?= =?UTF-8?q?ESI?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Myshipping.Application/EDI/PILEdiHelper.cs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Myshipping.Application/EDI/PILEdiHelper.cs b/Myshipping.Application/EDI/PILEdiHelper.cs index 11239890..1c622edf 100644 --- a/Myshipping.Application/EDI/PILEdiHelper.cs +++ b/Myshipping.Application/EDI/PILEdiHelper.cs @@ -673,7 +673,8 @@ namespace Myshipping.Application.EDI.PIL var estr = ""; if (InttrEdi.filetype == "E") { - estr = "ESI"; + //2023-03-28 确认需要把截单报文的文件名去掉ESI英文 + //estr = "ESI"; } else { From 8f120b9e29bb946c6c59fe7af389705d7c7d3b19 Mon Sep 17 00:00:00 2001 From: wanghaomei Date: Tue, 28 Mar 2023 14:16:06 +0800 Subject: [PATCH 6/6] =?UTF-8?q?=E6=97=A5=E5=BF=97=E6=9F=A5=E8=AF=A2?= =?UTF-8?q?=E6=9D=A1=E4=BB=B6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Myshipping.Core/Service/Log/Dto/OpLogInput.cs | 4 ++-- Myshipping.Core/Service/Log/SysOpLogService.cs | 3 +++ 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/Myshipping.Core/Service/Log/Dto/OpLogInput.cs b/Myshipping.Core/Service/Log/Dto/OpLogInput.cs index d485a1c8..13002352 100644 --- a/Myshipping.Core/Service/Log/Dto/OpLogInput.cs +++ b/Myshipping.Core/Service/Log/Dto/OpLogInput.cs @@ -8,7 +8,7 @@ namespace Myshipping.Core.Service; public class OpLogInput : PageInputBase { /// - /// 名称 + /// 操作人名称 /// public string Name { get; set; } @@ -83,7 +83,7 @@ public class OpLogInput : PageInputBase public DateTime OpTime { get; set; } /// - /// 操作人 + /// 操作人账号 /// public string Account { get; set; } } diff --git a/Myshipping.Core/Service/Log/SysOpLogService.cs b/Myshipping.Core/Service/Log/SysOpLogService.cs index c329640b..4a6047ae 100644 --- a/Myshipping.Core/Service/Log/SysOpLogService.cs +++ b/Myshipping.Core/Service/Log/SysOpLogService.cs @@ -34,6 +34,9 @@ public class SysOpLogService : ISysOpLogService, IDynamicApiController, ITransie { var opLogs = await _sysOpLogRep.AsQueryable() .WhereIF(!string.IsNullOrWhiteSpace(input.Name), u => u.Name.Contains(input.Name.Trim())) + .WhereIF(!string.IsNullOrWhiteSpace(input.Account), u => u.Name.Contains(input.Account.Trim())) + .WhereIF(!string.IsNullOrWhiteSpace(input.Ip), u => u.Name.Contains(input.Ip.Trim())) + .WhereIF(!string.IsNullOrWhiteSpace(input.Url), u => u.Name.Contains(input.Url.Trim())) .WhereIF(Enum.IsDefined(typeof(YesOrNot),input.Success), u => u.Success == input.Success) .WhereIF(!string.IsNullOrWhiteSpace(input.SearchBeginTime), u => u.OpTime >= DateTime.Parse(input.SearchBeginTime.Trim()) && u.OpTime <= DateTime.Parse(input.SearchEndTime.Trim())) .OrderBy(u => u.Id, OrderByType.Desc)