Commit 0b5d64bf 张东亮

扫码检查是否是CB开头

1 个父辈 f4e69dc4
...@@ -3,6 +3,7 @@ using OnlineStore.Common; ...@@ -3,6 +3,7 @@ using OnlineStore.Common;
using OnlineStore.LoadCSVLibrary; using OnlineStore.LoadCSVLibrary;
using System; using System;
using System.Collections.Generic; using System.Collections.Generic;
using System.Globalization;
using System.Linq; using System.Linq;
using System.Threading.Tasks; using System.Threading.Tasks;
...@@ -129,9 +130,17 @@ namespace DeviceLibrary ...@@ -129,9 +130,17 @@ namespace DeviceLibrary
} }
else else
{ {
MoveInfo.NextMoveStep(MoveStep.In05); var codes = x.Select((a) => a.CodeStr);
Lift.LiftDown(MoveInfo); if (codes.Any(s => !string.IsNullOrEmpty(s) && s.ToUpper().StartsWith("CB")))
MoveInfo.log($"放下入料阻挡"); {
MoveInfo.NextMoveStep(MoveStep.In05);
Lift.LiftDown(MoveInfo);
MoveInfo.log($"放下入料阻挡");
}
else
{
Msg.add($"扫到的料箱条码无CB开头,请确认:{string.Join(",", codes)}", MsgLevel.critical);
}
} }
} }
...@@ -228,7 +237,8 @@ namespace DeviceLibrary ...@@ -228,7 +237,8 @@ namespace DeviceLibrary
else if (MoveInfo.IsTimeOut(15)) else if (MoveInfo.IsTimeOut(15))
{ {
isScanErrorTimes++; isScanErrorTimes++;
if (isScanErrorTimes < 3) { if (isScanErrorTimes < 3)
{
MoveInfo.NextMoveStep(MoveStep.In03); MoveInfo.NextMoveStep(MoveStep.In03);
} }
else else
...@@ -281,7 +291,7 @@ namespace DeviceLibrary ...@@ -281,7 +291,7 @@ namespace DeviceLibrary
MoveInfo.NextMoveStep(MoveStep.InNG3); MoveInfo.NextMoveStep(MoveStep.InNG3);
Line.LineStop("work"); Line.LineStop("work");
MoveInfo.log($"料箱抵达出口"); MoveInfo.log($"料箱抵达出口");
if (isScanErrorTimes>2) if (isScanErrorTimes > 2)
Msg.add("入库周转箱扫码失败,请确认料箱方向后重试", MsgLevel.critical); Msg.add("入库周转箱扫码失败,请确认料箱方向后重试", MsgLevel.critical);
else else
Msg.add("入库周转箱超重,已退出,请处理", MsgLevel.critical); Msg.add("入库周转箱超重,已退出,请处理", MsgLevel.critical);
......
支持 Markdown 格式
你添加了 0 到此讨论。请谨慎行事。
Finish editing this message first!