Administrator 3 years ago
parent
commit
3c4e930beb
1 changed files with 7 additions and 7 deletions
  1. 7 7
      Projects/永冠OPP/WCS.Service/Extensions/DeviceExtension.cs

+ 7 - 7
Projects/永冠OPP/WCS.Service/Extensions/DeviceExtension.cs

@@ -530,7 +530,7 @@ namespace WCS.Service.Extensions
             var station = Device.Find($"G{target}").Create<StationDeviceGroup>();
             var station = Device.Find($"G{target}").Create<StationDeviceGroup>();
 
 
             //当前RGV与目标站台的距离小于传入RGV到达目标站台的距离
             //当前RGV与目标站台的距离小于传入RGV到达目标站台的距离
-            return (this.Distance(station) < rgv.Distance(station)) || station.CurrentRGV()?.Entity == this.Entity;
+            return (this.Distance(station) < rgv.Distance(station)) || station.CurrentRGV()?.Entity.CODE == this.Entity.CODE;
         }
         }
 
 
         /// <summary>
         /// <summary>
@@ -909,12 +909,12 @@ namespace WCS.Service.Extensions
         static StationLocation()
         static StationLocation()
         {
         {
             ALLlocations.AddRange(new List<StationLocation>() {
             ALLlocations.AddRange(new List<StationLocation>() {
-                new StationLocation("G1187",0,"RGV1",0),
-                new StationLocation("G1196",0,"RGV1",0),
-                new StationLocation("G1205",0,"RGV1",0),
-                new StationLocation("G1214",0,"RGV1",0),
-                new StationLocation("G1222",0,"RGV1",0),
-                new StationLocation("G1164",0,"RGV1",0),
+                //new StationLocation("G1187",0,"RGV1",0),
+                //new StationLocation("G1196",0,"RGV1",0),
+                //new StationLocation("G1205",0,"RGV1",0),
+                //new StationLocation("G1214",0,"RGV1",0),
+                //new StationLocation("G1222",0,"RGV1",0),
+                //new StationLocation("G1164",0,"RGV1",0),
                 new StationLocation("G1",486326,"RGV3",1567770),
                 new StationLocation("G1",486326,"RGV3",1567770),
                 new StationLocation("G2",693631,"RGV3",1567770),
                 new StationLocation("G2",693631,"RGV3",1567770),
                 new StationLocation("G3",789931,"RGV3",1567770),
                 new StationLocation("G3",789931,"RGV3",1567770),