| | |
| | | |
| | | if (Config.Instance.Home.IsVirtually) |
| | | { |
| | | Send.Zj(LogicView.IfString.Tag, Common.Logic.CurrentLogic); |
| | | //自动化逻辑列表 |
| | | if (CurrentLogic.LogicId == 0) |
| | | { |
| | | bool d = false; |
| | | for (int i = 1; i < 50; i++) |
| | | { |
| | | for (int j = 0; j < Common.Logic.LogicList.Count; j++) |
| | | { |
| | | if (i != Common.Logic.LogicList[j].LogicId) |
| | | { |
| | | CurrentLogic.LogicId = i; |
| | | Common.Logic.LogicList.Add(CurrentLogic); |
| | | d = true; |
| | | break; |
| | | } |
| | | } |
| | | if (d) |
| | | { |
| | | break; |
| | | } |
| | | } |
| | | |
| | | } |
| | | else |
| | | { |
| | | for (int j = 0; j < Common.Logic.LogicList.Count; j++) |
| | | { |
| | | if (j == Common.Logic.LogicList[j].LogicId) |
| | | { |
| | | Common.Logic.LogicList.RemoveAt(j); |
| | | Common.Logic.LogicList.Insert(j,CurrentLogic); |
| | | break; |
| | | } |
| | | } |
| | | |
| | | } |
| | | |
| | | //自动化逻辑列表 |
| | | } |
| | | else |
| | | { |