| | |
| | | List<CommonDevice> list = Common.LocalDevice.Current.GetDeviceByGatewayID(gatewayId);
|
| | | foreach (var device in list)
|
| | | {
|
| | | //删除设备,不删除房间信息
|
| | | Common.LocalDevice.Current.DeleteMemmoryDevice(device, false);
|
| | | //删除一般设备
|
| | | Common.LocalDevice.Current.DeleteMemmoryDevice(device, true);
|
| | | //删除Ota设备
|
| | | Common.LocalDevice.Current.DeleteMemmoryOtaDevice(device.DeviceAddr);
|
| | | }
|
| | | //删除网关文件
|
| | | this.DeleteGatewayFile(gatewayId);
|
| | |
| | | {
|
| | | //删除设备文件
|
| | | Common.LocalDevice.Current.DeleteMemmoryDevice(device, true);
|
| | | //删除Ota设备
|
| | | Common.LocalDevice.Current.DeleteMemmoryOtaDevice(device.DeviceAddr);
|
| | | }
|
| | | //如果是主网关
|
| | | if (this.IsMainGateway(zbGatewayID) == 1)
|