| | |
| | | |
| | | new System.Threading.Thread(() => |
| | | { |
| | | if (collect) |
| | | { |
| | | result = ApiUtlis.Ins.HttpRequest.CollectDevice(deviceId).Code; |
| | | if (spk == SPK.GroupControl) { |
| | | if (collect) |
| | | { |
| | | } |
| | | else |
| | | { |
| | | } |
| | | } |
| | | else |
| | | { |
| | | result = ApiUtlis.Ins.HttpRequest.CancelCollectDevice(deviceId).Code; |
| | | if (collect) |
| | | { |
| | | result = ApiUtlis.Ins.HttpRequest.CollectDevice(deviceId).Code; |
| | | } |
| | | else |
| | | { |
| | | result = ApiUtlis.Ins.HttpRequest.CancelCollectDevice(deviceId).Code; |
| | | } |
| | | } |
| | | //提示错误 |
| | | if (result != StateCode.SUCCESS) |
| | |
| | | public static class SPK |
| | | { |
| | | /// <summary> |
| | | /// 群控(自定义) |
| | | /// </summary> |
| | | public const string GroupControl = "GroupControl"; |
| | | /// <summary> |
| | | /// 通用开关 |
| | | /// </summary> |
| | | public const string OtherCommon = "other.common"; |