| | |
| | | var list = TaskHelper.GetTaskListByState("未执行"); |
| | | if (list.Count > 0) |
| | | { |
| | | foreach (var mst in list) |
| | | { |
| | | var dinfo = Settings.GetDeviceInfoList().FindAll(x => x.deviceType == 13); |
| | | if (dinfo.Find(x => x.location.Contains(mst.S_START_LOC)) != null) |
| | | mst.N_PRIORITY = 99; |
| | | else |
| | | if (dinfo.Find(x => x.location.Contains(mst.S_END_LOC)) != null) |
| | | mst.N_PRIORITY = 98; |
| | | } |
| | | list = list.OrderByDescending(x => x.N_PRIORITY).ToList(); |
| | | //foreach (var mst in list) |
| | | //{ |
| | | // var dinfo = Settings.GetDeviceInfoList().FindAll(x => x.deviceType == 13); |
| | | // if (dinfo.Find(x => x.location.Contains(mst.S_START_LOC)) != null) |
| | | // mst.N_PRIORITY = 99; |
| | | // else |
| | | // if (dinfo.Find(x => x.location.Contains(mst.S_END_LOC)) != null) |
| | | // mst.N_PRIORITY = 98; |
| | | //} |
| | | //list = list.OrderByDescending(x => x.N_PRIORITY).ToList(); |
| | | |
| | | list.ForEach(task => |
| | | { |