|
@@ -23,7 +23,7 @@ public class DeviceAlertDelayController {
|
|
|
*/
|
|
*/
|
|
|
@PostMapping("/{deviceId}")
|
|
@PostMapping("/{deviceId}")
|
|
|
public CommonResult<String> disableDeviceAlert(@PathVariable String deviceId, @RequestParam(defaultValue = "1") long hours) {
|
|
public CommonResult<String> disableDeviceAlert(@PathVariable String deviceId, @RequestParam(defaultValue = "1") long hours) {
|
|
|
- hours = 5 / 60;
|
|
|
|
|
|
|
+// hours = 5 / 60;
|
|
|
delayService.disableDeviceAlert(deviceId, hours);
|
|
delayService.disableDeviceAlert(deviceId, hours);
|
|
|
return CommonResult.data(String.format("设备[%s] 预警已禁用 %d 小时", deviceId, hours));
|
|
return CommonResult.data(String.format("设备[%s] 预警已禁用 %d 小时", deviceId, hours));
|
|
|
}
|
|
}
|
|
@@ -35,7 +35,7 @@ public class DeviceAlertDelayController {
|
|
|
*/
|
|
*/
|
|
|
@PostMapping("/{deviceId}/channel/{channelNo}")
|
|
@PostMapping("/{deviceId}/channel/{channelNo}")
|
|
|
public CommonResult<String> disableChannelAlert(@PathVariable String deviceId, @PathVariable int channelNo, @RequestParam(defaultValue = "1") long hours) {
|
|
public CommonResult<String> disableChannelAlert(@PathVariable String deviceId, @PathVariable int channelNo, @RequestParam(defaultValue = "1") long hours) {
|
|
|
- hours = 5 / 60;
|
|
|
|
|
|
|
+// hours = 5 / 60;
|
|
|
delayService.disableChannelAlert(deviceId, channelNo, hours);
|
|
delayService.disableChannelAlert(deviceId, channelNo, hours);
|
|
|
return CommonResult.data(String.format("设备[%s] 第[%d]路预警已禁用 %d 小时", deviceId, channelNo, hours));
|
|
return CommonResult.data(String.format("设备[%s] 第[%d]路预警已禁用 %d 小时", deviceId, channelNo, hours));
|
|
|
}
|
|
}
|