mirror of
https://codeup.aliyun.com/67c68d4e484ca2f0a13ac3c1/ydc/jsowell-charger-web.git
synced 2026-04-22 12:05:05 +08:00
新增 相机相关Service方法
This commit is contained in:
@@ -7,11 +7,15 @@ import com.jsowell.common.core.controller.BaseController;
|
||||
import com.jsowell.pile.dto.camera.CameraHeartBeatDTO;
|
||||
import com.jsowell.pile.dto.camera.CameraIdentifyResultsDTO;
|
||||
import com.jsowell.thirdparty.camera.common.CameraCommonResult;
|
||||
import com.jsowell.thirdparty.camera.service.CameraService;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
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;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 充电相机 controller
|
||||
*
|
||||
@@ -22,6 +26,8 @@ import org.springframework.web.bind.annotation.RestController;
|
||||
@RestController
|
||||
@RequestMapping("/camera")
|
||||
public class CameraController extends BaseController {
|
||||
@Autowired
|
||||
private CameraService cameraService;
|
||||
|
||||
/**
|
||||
* 心跳
|
||||
@@ -40,8 +46,11 @@ public class CameraController extends BaseController {
|
||||
* @param jsonObject
|
||||
*/
|
||||
@PostMapping("/v1/receiveIdentifyResults")
|
||||
public void receiveIdentifyResults(@RequestBody JSONObject jsonObject) {
|
||||
public CameraCommonResult receiveIdentifyResults(@RequestBody JSONObject jsonObject) {
|
||||
logger.info("相机系统接收识别结果 params:{}", jsonObject);
|
||||
|
||||
CameraCommonResult result = new CameraCommonResult();
|
||||
// 调用service方法处理
|
||||
cameraService.receiveIdentifyResults(jsonObject);
|
||||
return result.successResponse();
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user