| | |
| | | deviceService.devicePropertySet(workspaceId, dockSn, propertyEnumOpt.get(), param.get(property)); |
| | | return ResponseResult.success(); |
| | | } |
| | | |
| | | /** |
| | | * 红外设置方法 |
| | | * @param workspaceId |
| | | * @param dockSn |
| | | * @param param |
| | | * @return |
| | | */ |
| | | @PutMapping("/{workspace_id}/devices/{device_sn}/property2") |
| | | public ResponseResult devicePropertySet2(@PathVariable("workspace_id") String workspaceId, |
| | | @PathVariable("device_sn") String dockSn, |
| | | @RequestBody JsonNode param) { |
| | | if (param.size() != 1) { |
| | | return ResponseResult.error(CommonErrorEnum.ILLEGAL_ARGUMENT); |
| | | } |
| | | int result = deviceService.devicePropertySet(workspaceId, dockSn, param); |
| | | return ResponseResult.success().getCode() == result ?ResponseResult.success():ResponseResult.error(); |
| | | } |
| | | |
| | | } |