舞台接口更新
This commit is contained in:
@@ -1,27 +1,38 @@
|
||||
package org.nl.acs.monitor.rest;
|
||||
|
||||
import com.alibaba.fastjson.JSONArray;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import lombok.RequiredArgsConstructor;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.nl.acs.monitor.service.DeviceStageMonitorService;
|
||||
import org.nl.annotation.Log;
|
||||
import org.springframework.http.HttpStatus;
|
||||
import org.springframework.http.ResponseEntity;
|
||||
import org.springframework.web.bind.annotation.PostMapping;
|
||||
import org.springframework.web.bind.annotation.RequestBody;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
|
||||
/**
|
||||
* @Author: lyd
|
||||
* @Description:
|
||||
* @Description: 设备信息
|
||||
* @Date: 2022-08-17
|
||||
*/
|
||||
@Slf4j
|
||||
@RestController
|
||||
@RequiredArgsConstructor
|
||||
@Api(tags = "设备信息")
|
||||
@RequestMapping("/api/deviceInfo")
|
||||
public class DeviceStageMonitorController {
|
||||
|
||||
private final DeviceStageMonitorService deviceStageMonitorService;
|
||||
|
||||
|
||||
// @PostMapping("/getDeviceByCodes")
|
||||
// @Log("获取舞台设备信息")
|
||||
// @ApiOperation("获取舞台设备信息")
|
||||
// public ResponseEntity<Object> getDeviceByCodes(@RequestBody String json) throws Exception{
|
||||
// JSONArray jsonArray = JSONArray.parseArray(json);
|
||||
// return new ResponseEntity<>(stageService.getDeviceByCodes(jsonArray), HttpStatus.OK);
|
||||
// }
|
||||
@Log("获取舞台设备信息")
|
||||
@ApiOperation("获取舞台设备信息")
|
||||
@PostMapping("/getDeviceByCodes")
|
||||
public ResponseEntity<Object> getDeviceByCodes(@RequestBody String json) {
|
||||
JSONArray jsonArray = JSONArray.parseArray(json);
|
||||
return new ResponseEntity<>(deviceStageMonitorService.getData(jsonArray), HttpStatus.OK);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user