| | |
| | | import com.dji.sample.control.model.param.DrcConnectParam; |
| | | import com.dji.sample.control.model.param.DrcModeParam; |
| | | import com.dji.sample.control.service.IDrcService; |
| | | import com.dji.sample.log.aspect.SysLogAnnotation; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.web.bind.annotation.*; |
| | |
| | | private IDrcService drcService; |
| | | |
| | | @PostMapping("/workspaces/{workspace_id}/drc/connect") |
| | | @SysLogAnnotation(operModul = "drc控制", operType = "控制指令", operDesc = "控制指令") |
| | | public ResponseResult drcConnect(@PathVariable("workspace_id") String workspaceId, HttpServletRequest request, @Valid @RequestBody DrcConnectParam param) { |
| | | CustomClaim claims = (CustomClaim) request.getAttribute(TOKEN_CLAIM); |
| | | |
| | |
| | | } |
| | | |
| | | @PostMapping("/workspaces/{workspace_id}/drc/enter") |
| | | @SysLogAnnotation(operModul = "drc控制", operType = "控制指令", operDesc = "进入控制") |
| | | public ResponseResult drcEnter(@PathVariable("workspace_id") String workspaceId, @Valid @RequestBody DrcModeParam param) { |
| | | JwtAclDTO acl = drcService.deviceDrcEnter(workspaceId, param); |
| | | |
| | |
| | | } |
| | | |
| | | @PostMapping("/workspaces/{workspace_id}/drc/exit") |
| | | @SysLogAnnotation(operModul = "drc控制", operType = "控制指令", operDesc = "退出控制") |
| | | public ResponseResult drcExit(@PathVariable("workspace_id") String workspaceId, @Valid @RequestBody DrcModeParam param) { |
| | | drcService.deviceDrcExit(workspaceId, param); |
| | | |