| | |
| | | package com.stylefeng.guns.modular.api; |
| | | |
| | | import com.alibaba.fastjson.JSON; |
| | | import com.baomidou.mybatisplus.plugins.Page; |
| | | import com.stylefeng.guns.core.base.controller.BaseController; |
| | | import com.stylefeng.guns.core.common.constant.JwtConstants; |
| | |
| | | import com.stylefeng.guns.modular.system.util.videoGateway.VideoGateway; |
| | | import com.stylefeng.guns.modular.system.util.videoGateway.model.Ship; |
| | | import com.stylefeng.guns.modular.system.util.videoGateway.model.Vehicle; |
| | | import com.stylefeng.guns.modular.system.warpper.VehicleSpeed; |
| | | import io.swagger.annotations.ApiImplicitParam; |
| | | import io.swagger.annotations.ApiImplicitParams; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | import org.springframework.web.bind.annotation.*; |
| | | |
| | | import javax.annotation.Resource; |
| | |
| | | * @author zhibing.pu |
| | | * @Date 2024/12/17 20:18 |
| | | */ |
| | | @Slf4j |
| | | @RestController |
| | | @RequestMapping("") |
| | | public class PatrolTaskController extends BaseController { |
| | |
| | | } |
| | | |
| | | |
| | | @PutMapping("/base/patrolTask/vehicleSpeed") |
| | | @PostMapping("/base/patrolTask/vehicleSpeed") |
| | | @ApiOperation(value = "变更车辆状态", tags = {"互联互通接口"}) |
| | | @ApiImplicitParams({ |
| | | @ApiImplicitParam(value = "车牌号", name = "vehicleNum", dataType = "String", required = true), |
| | |
| | | @ApiImplicitParam(value = "纬度", name = "latitude", dataType = "double", required = true), |
| | | @ApiImplicitParam(value = "经度", name = "longitude", dataType = "double", required = true), |
| | | }) |
| | | public ResultUtil vehicleSpeed(String vehicleNum, Integer vehicleStatus, Integer vehicleType, String communicationNum, String vehicleGpsProtocol, Double latitude, Double longitude){ |
| | | patrolTaskService.vehicleSpeed(vehicleNum, vehicleStatus, vehicleType, communicationNum, vehicleGpsProtocol, latitude, longitude); |
| | | public ResultUtil vehicleSpeed(@RequestBody VehicleSpeed vehicleSpeed){ |
| | | log.info("推送车辆状态:{}", JSON.toJSONString(vehicleSpeed)); |
| | | patrolTaskService.vehicleSpeed(vehicleSpeed.getVehicleNum(), vehicleSpeed.getVehicleStatus(), vehicleSpeed.getVehicleType(), |
| | | vehicleSpeed.getCommunicationNum(), vehicleSpeed.getVehicleGpsProtocol(), vehicleSpeed.getLatitude(), vehicleSpeed.getLongitude()); |
| | | return ResultUtil.success(); |
| | | } |
| | | } |