gkj 2 жил өмнө
parent
commit
d67b12a454

+ 5 - 0
WCS.Entity.Protocol/Station/StationEnum.cs

@@ -44,26 +44,31 @@ namespace WCS.Entity.Protocol.Station
         /// <summary>
         /// 自动
         /// </summary>
+        [Description("自动")]
         Auto = 1 << 0,
 
         /// <summary>
         /// 选中状态位
         /// </summary>
+        [Description("自动")]
         Choice_Bit = 1 << 1,
 
         /// <summary>
         /// 任务有货
         /// </summary>
+        [Description("自动")]
         OT_Status = 1 << 2,
 
         /// <summary>
         /// 光电有货
         /// </summary>
+        [Description("自动")]
         PH_Status = 1 << 3,
 
         /// <summary>
         /// 运行状态位
         /// </summary>
+        [Description("自动")]
         Run = 1 << 4,
 
         /// <summary>

+ 3 - 3
WCS.WorkEngineering/Systems/一楼入库工位处理系统.cs

@@ -63,14 +63,14 @@ namespace WCS.WorkEngineering.Systems
                    //获取称重
                    var dev91 = Device.All.Where(v => v.Code == obj.Entity.Code).Select(v => new Device<IStation91>(v, this.World)).FirstOrDefault();
                    task.Weight = dev91.Data.Weight;
-                   if (task.Weight == 0) throw new KnownException($"称重结果为零", LogLevelEnum.Mid);
+                   if (task.Weight <=500) throw new KnownException($"称重结果错误", LogLevelEnum.Mid);
                }
                catch (Exception ex)
                {
                    World.Log($"称重读取记录:{ex.Message}", LogLevelEnum.Low);
-                   if (ex.Message == "称重结果为零")
+                   if (ex.Message == "称重结果错误")
                    {
-                       throw new KnownException($"称重结果为零:{task.Weight}", LogLevelEnum.Mid);
+                       throw new KnownException($"称重结果错误:{task.Weight}", LogLevelEnum.Mid);
                    }
                }