From a296223898d61a9838bbd35ed75c87575e308a36 Mon Sep 17 00:00:00 2001
From: huangxiaoqiang <huangxiaoqiang@hnkhzn.com>
Date: 星期五, 07 十一月 2025 17:19:38 +0800
Subject: [PATCH] 1
---
项目代码/WMS/WIDESEA_WMSServer/WIDESEA_OrderServices/Dt_InboundOrderService.cs | 18 +++++++++++-------
1 files changed, 11 insertions(+), 7 deletions(-)
diff --git "a/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WIDESEA_WMSServer/WIDESEA_OrderServices/Dt_InboundOrderService.cs" "b/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WIDESEA_WMSServer/WIDESEA_OrderServices/Dt_InboundOrderService.cs"
index 73a7a9b..13e300e 100644
--- "a/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WIDESEA_WMSServer/WIDESEA_OrderServices/Dt_InboundOrderService.cs"
+++ "b/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WIDESEA_WMSServer/WIDESEA_OrderServices/Dt_InboundOrderService.cs"
@@ -1,5 +1,6 @@
锘縰sing MailKit.Search;
using Masuit.Tools;
+using Newtonsoft.Json;
using WIDESEA_Common;
using WIDESEA_Core;
using WIDESEA_Core.BaseRepository;
@@ -62,12 +63,12 @@
inboundOrders.Add(InboundOrder);
}
}
- PrintInbound(inboundOrders);
- return content.OK("鎴愬姛");
+ content=PrintInbound(inboundOrders);
+ return content;
}
catch (Exception ex)
{
- return content.Error(ex.Message);
+ return content.Error("鏈煡閿欒锛岃鑱旂郴绠$悊鍛�");
}
}
@@ -81,12 +82,12 @@
{
PalletCodes.Add(GetOrderPintCode("PalletCodes"));
}
- PrintPallet(PalletCodes);
+ content= PrintPallet(PalletCodes);
return content.OK();
}
catch (Exception ex)
{
- return content.Error(ex.Message);
+ return content.Error("鏈煡閿欒锛岃鑱旂郴绠$悊鍛�");
}
}
public string GetOrderPintCode(string printCode)
@@ -108,7 +109,7 @@
SqlSugarHelper.DbWMS.Updateable(PrintSetting).ExecuteCommand();
return PrintCode;
}
- public void PrintPallet(List<string> palletCodes)
+ public WebResponseContent PrintPallet(List<string> palletCodes)
{
var configs = _configService.GetConfigsByCategory(CateGoryConst.CONFIG_SYS_IPAddress);
var Base = configs.FirstOrDefault(x => x.ConfigKey == SysConfigConst.PrintIPAddress)?.ConfigValue;
@@ -119,10 +120,12 @@
}
var IpAddress = Base + ipAddress;
var result = HttpsClient.PostAsync(IpAddress, palletCodes.ToJsonString()).Result;
+ return JsonConvert.DeserializeObject<WebResponseContent>(result);
}
- public void PrintInbound(List<Dt_InboundOrder> orders)
+ public WebResponseContent PrintInbound(List<Dt_InboundOrder> orders)
{
+ WebResponseContent content = new WebResponseContent();
var configs = _configService.GetConfigsByCategory(CateGoryConst.CONFIG_SYS_IPAddress);
var Base = configs.FirstOrDefault(x => x.ConfigKey == SysConfigConst.PrintIPAddress)?.ConfigValue;
var ipAddress = configs.FirstOrDefault(x => x.ConfigKey == SysConfigConst.PrintInboundOrder)?.ConfigValue;
@@ -132,6 +135,7 @@
}
var IpAddress = Base + ipAddress;
var result = HttpsClient.PostAsync(IpAddress, orders.ToJsonString()).Result;
+ return JsonConvert.DeserializeObject<WebResponseContent>(result);
}
}
}
--
Gitblit v1.9.3