Commit 1f67d6e9 顾剑亮

取旧钢板时不要去前面的产线

1 个父辈 4c744f63
...@@ -78,12 +78,16 @@ namespace BLL ...@@ -78,12 +78,16 @@ namespace BLL
public bool FindOldSteelWork(AgvInfo info, out string place) public bool FindOldSteelWork(AgvInfo info, out string place)
{ {
place = null;
int index = -1; int index = -1;
string name = ""; string name = "";
bool find = false; bool find = false;
int placeIdx = Array.FindIndex(Common.PLACE_NAME, s => s == info.Place);
if (placeIdx == -1) return false;
string s = info.Workshop.Substring(1, 1); string s = info.Workshop.Substring(1, 1);
for (int i = 0; i < Common.PLACE_NAME.Length; i++) for (int i = placeIdx; i < Common.PLACE_NAME.Length; i++)
{ {
name = Common.PLACE_NAME[i]; name = Common.PLACE_NAME[i];
if (name.StartsWith(s)) if (name.StartsWith(s))
......
支持 Markdown 格式
你添加了 0 到此讨论。请谨慎行事。
Finish editing this message first!