This commit is contained in:
hehaibing-1996
2024-05-28 08:59:48 +08:00

View File

@ -887,7 +887,7 @@ namespace WCS.BLL.Services.Service
for (int i = 0; i < si.Count; i++)
{
TCPClient tCPClient = TCPClientManager.GetTCPClientByIPHost(si[i].ClientIp);
byte[] warnlightOn = Helper.OutstoreWarnLight(si[i].LightId,"无",1,0);
byte[] warnlightOn = Helper.OutstoreWarnLight(si[i].LightId,LightColor,1,0);
tCPClient.Send(warnlightOn);
Thread.Sleep(100);
}
@ -1182,6 +1182,16 @@ namespace WCS.BLL.Services.Service
//需要出库的货架名
List<string> StoreCode = new List<string>();
//库位灯灭灯
string LightColor = "无";
try
{
List<OrderLight> ol = DbHelp.db.Queryable<OrderLight>().Where(it => it.OrderNumber == request.OrderNumber).ToList();
LightColor = ol[0].LightColor;
}
catch (Exception ee)
{
Logs.Write("查询出库单据:"+request.OrderNumber+"对应库位灯颜色失败,"+ ee.Message);
}
Dictionary<string, List<int>> dict = new Dictionary<string, List<int>>();
foreach (OutOrderMatDetail oomd in outOrderMatDetails)
{
@ -1217,7 +1227,7 @@ namespace WCS.BLL.Services.Service
{
string sendIP = v.Key;
TCPClient tCPClient = TCPClientManager.GetTCPClientByIPHost(sendIP);
byte[] lightOn = Helper.OutstoreLight(v.Value, "无",0);
byte[] lightOn = Helper.OutstoreLight(v.Value, LightColor,0);
tCPClient.Send(lightOn);
Thread.Sleep(100);
}
@ -1242,7 +1252,7 @@ namespace WCS.BLL.Services.Service
for (int i = 0; i < si.Count; i++)
{
TCPClient tCPClient = TCPClientManager.GetTCPClientByIPHost(si[i].ClientIp);
byte[] warnlightOn = Helper.OutstoreWarnLight(si[i].LightId, "无", 0, 0);
byte[] warnlightOn = Helper.OutstoreWarnLight(si[i].LightId, LightColor, 0, 0);
tCPClient.Send(warnlightOn);
Thread.Sleep(100);
}