From 6057b8d928380f2251a4fb9d9e37326c464a3033 Mon Sep 17 00:00:00 2001 From: wet <1034391973@qq.com> Date: Fri, 24 Mar 2023 11:12:50 +0800 Subject: [PATCH] =?UTF-8?q?=E6=8F=90=E5=8D=95=E5=8F=B7=E9=AA=8C=E8=AF=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Service/DataSync/DataSyncService.cs | 26 +++++++------------ 1 file changed, 10 insertions(+), 16 deletions(-) diff --git a/Myshipping.Application/Service/DataSync/DataSyncService.cs b/Myshipping.Application/Service/DataSync/DataSyncService.cs index 85750f28..66608d2f 100644 --- a/Myshipping.Application/Service/DataSync/DataSyncService.cs +++ b/Myshipping.Application/Service/DataSync/DataSyncService.cs @@ -303,16 +303,12 @@ namespace Myshipping.Application { foreach (var item in model.childrens) { - if (string.IsNullOrWhiteSpace(item.MBLNO)) - { - throw Oops.Bah("请填写提单号!"); - } + + JsonUtil.PropToUpper(item, "ORDNO", "BSSTATUS", "YardContract", "YardContractTel", "YardContractEmail", "MARKS", "DESCRIPTION", "CONSIGNEENAME", "SHIPPERNAME", "NOTIFYPARTYNAME"); if (string.IsNullOrWhiteSpace(item.HBLNO)) { throw Oops.Bah("请填写分提单号!"); } - JsonUtil.PropToUpper(item, "ORDNO", "BSSTATUS", "YardContract", "YardContractTel", "YardContractEmail", "MARKS", "DESCRIPTION", "CONSIGNEENAME", "SHIPPERNAME", "NOTIFYPARTYNAME"); - var fms = JsonUtil.TrimFields(item); if (!string.IsNullOrEmpty(fms)) { @@ -629,12 +625,12 @@ namespace Myshipping.Application { foreach (var item in model.childrens) { - if (string.IsNullOrWhiteSpace(item.MBLNO)) + + JsonUtil.PropToUpper(item, "ORDNO", "BSSTATUS", "YardContract", "YardContractTel", "YardContractEmail", "MARKS", "DESCRIPTION", "CONSIGNEENAME", "SHIPPERNAME", "NOTIFYPARTYNAME"); + if (string.IsNullOrWhiteSpace(item.HBLNO)) { - throw Oops.Bah("请填写提单号!"); + throw Oops.Bah("请填写分提单号!"); } - JsonUtil.PropToUpper(item, "ORDNO", "BSSTATUS", "YardContract", "YardContractTel", "YardContractEmail", "MARKS", "DESCRIPTION", "CONSIGNEENAME", "SHIPPERNAME", "NOTIFYPARTYNAME"); - var fms = JsonUtil.TrimFields(item); if (!string.IsNullOrEmpty(fms)) { @@ -1028,10 +1024,7 @@ namespace Myshipping.Application { foreach (var item in model.childrens) { - if (string.IsNullOrWhiteSpace(item.MBLNO)) - { - throw Oops.Bah("请填写提单号!"); - } + if (string.IsNullOrWhiteSpace(item.HBLNO)) { throw Oops.Bah("请填写分提单号!"); @@ -1348,9 +1341,10 @@ namespace Myshipping.Application { foreach (var item in model.childrens) { - if (string.IsNullOrWhiteSpace(item.MBLNO)) + + if (string.IsNullOrWhiteSpace(item.HBLNO)) { - throw Oops.Bah("请填写提单号!"); + throw Oops.Bah("请填写分提单号!"); } JsonUtil.PropToUpper(item, "ORDNO", "BSSTATUS", "YardContract", "YardContractTel", "YardContractEmail", "MARKS", "DESCRIPTION", "CONSIGNEENAME", "SHIPPERNAME", "NOTIFYPARTYNAME");