From 47dbb11d9b8d60ea6b72bc85bd9d5f1116aa403a Mon Sep 17 00:00:00 2001 From: jianghaiqing Date: Mon, 25 Nov 2024 11:42:07 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9VOLTA=20=E8=B4=A7=E6=8F=8F70?= =?UTF-8?q?=E6=94=B944=EF=BC=8C=E5=94=9B=E5=A4=B435=E6=94=B932=EF=BC=8CHSC?= =?UTF-8?q?ODE=E8=A6=81=E6=B1=824=E4=BD=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../EDI/VOLTAEdiNewHelper.cs | 20 +++++++++++++++---- 1 file changed, 16 insertions(+), 4 deletions(-) diff --git a/Myshipping.Application/EDI/VOLTAEdiNewHelper.cs b/Myshipping.Application/EDI/VOLTAEdiNewHelper.cs index b54e7bbd..2fcba1e5 100644 --- a/Myshipping.Application/EDI/VOLTAEdiNewHelper.cs +++ b/Myshipping.Application/EDI/VOLTAEdiNewHelper.cs @@ -429,7 +429,7 @@ namespace Myshipping.Application.EDI.VOLTA } else { - error += formatlengthError("txt", headData.MARKS, 35, headData.MBLNO, "唛头", 0, "", false); + error += formatlengthError("txt", headData.MARKS, 32, headData.MBLNO, "唛头", 0, "", false);//2024-11-25 董怡含转达VOLTA 35调整为单行32个字符 } } @@ -465,10 +465,22 @@ namespace Myshipping.Application.EDI.VOLTA } else { - //error += formatlengthError("txt", bill.DESCRIPTION, 35, bill.MBLNO, "货物描述", 0, ""); + error += formatlengthError("txt", headData.DESCRIPTION, 44, headData.MBLNO, "货物描述", 0, "",false);//2024-11-25 董怡含转达VOLTA 70调整为单行44个字符 } } + if (InttrEdi.filetype == "E") + { + if (string.IsNullOrWhiteSpace(headData.HSCODE)) + { + error = error + "
提单号:" + headData.MBLNO + " HSCODE不能为空"; + } + + if (!string.IsNullOrWhiteSpace(headData.HSCODE) && (headData.HSCODE.Length > 4 || headData.HSCODE.Length < 4)) + { + error = error + "
提单号:" + headData.MBLNO + " HSCODE请填写4位的真实HSCODE"; + } + } if (string.IsNullOrEmpty(headData.SHIPPER)) { @@ -1034,7 +1046,7 @@ namespace Myshipping.Application.EDI.VOLTA } Shipping = formatEdiStr("txt", bill.MARKS); - ShippingList = formatlengthStr(Shipping, 35); + ShippingList = formatlengthStr(Shipping, 32);//2024-11-25 董怡含确认VOLTA官方改报文了 原来35改为32了 //for (var i = 0; i < Math.Ceiling(Convert.ToDecimal(Convert.ToDecimal(ShippingList.Count) / Convert.ToDecimal(10))); i++) //{ @@ -1064,7 +1076,7 @@ namespace Myshipping.Application.EDI.VOLTA } Shipping = formatEdiStr("txt", bill.DESCRIPTION); - ShippingList = formatlengthStr(Shipping, 70); + ShippingList = formatlengthStr(Shipping, 44);//2024-11-25 董怡含确认VOLTA官方改报文了 原来70改为44了 var m = 1; var strtemp = "";