old mode 100755
new mode 100644
| | |
| | | // The remote server returned an error: (400) Bad Request. |
| | | string url = "https://developer.hdlcontrol.com/zigbeespeakerservice/BatchEdit"; |
| | | string json = Newtonsoft.Json.JsonConvert.SerializeObject(SmartSound.getInstantiate()); |
| | | string response_str = await MyHttpWebResponse.PostWebRequest(url, json, Encoding.UTF8); |
| | | string response_str = MyHttpWebResponse.PostWebRequest(url, json, Encoding.UTF8); |
| | | return response_str; |
| | | } |
| | | |
| | |
| | | continue; |
| | | |
| | | SmartSound.Device smartDevice = new SmartSound.Device(); |
| | | //smartDevice.Id = device.DeviceID.ToString();//设备 Id |
| | | smartDevice.DeviceAddress = device.DeviceAddr;//设备 MAC |
| | | smartDevice.Epoint = device.DeviceEpoint;//设备端口 |
| | | //smartDevice.ClusterID = 0; |
| | | smartDevice.DeviceName = device.DeviceName;//设备名称 |
| | | smartDevice.DeviceName = Common.LocalDevice.Current.GetDeviceEpointName(device);//设备名称 |
| | | smartDevice.NicksName = ""; |
| | | smartDevice.DeviceType = GetDeviceType(device);//设备类型 |
| | | smartDevice.GatewayID = device.CurrentGateWayId;//网关 Id |
| | | //smartDevice.RoomID = room.Id;//房间 Id |
| | | if (smartDevice.DeviceName == "" || smartDevice.DeviceName == string.Empty) |
| | | continue; |
| | | |
| | |
| | | |
| | | if (scene == null) continue; |
| | | SmartSound.Scene smartScene = new SmartSound.Scene(); |
| | | //smartScene.Id = scene.DeviceID.ToString(); |
| | | smartScene.SceneName = scene.Name; |
| | | smartScene.SceneID = scene.Id; |
| | | smartScene.DelayTime = scene.DelayTime; |
| | | //smartScene.ClusterID = 0; |
| | | smartScene.NicksName = ""; |
| | | //smartScene.RoomID = room.Id; |
| | | smartScene.GatewayID = ZbGateway.MainGateWay.GwId; |
| | | |
| | | if (smartScene.SceneName == "" || smartScene.SceneName == string.Empty) |
| | |
| | | } |
| | | #endregion |
| | | |
| | | if (room.ListDevice.Count == 0 && sceneList.Count == 0) |
| | | layer.RoomList.Remove(smartRoom); |
| | | |
| | | } |
| | | catch (Exception e) |
| | | { |