Commit 3abee786 by chenxi

实现功能:修改读取实时监测数据接口路径

1 parent 384640ac
...@@ -12,8 +12,8 @@ import com.glsx.plat.core.web.R; ...@@ -12,8 +12,8 @@ import com.glsx.plat.core.web.R;
import io.swagger.v3.oas.annotations.Operation; import io.swagger.v3.oas.annotations.Operation;
import io.swagger.v3.oas.annotations.tags.Tag; import io.swagger.v3.oas.annotations.tags.Tag;
import lombok.extern.slf4j.Slf4j; import lombok.extern.slf4j.Slf4j;
import org.apache.ibatis.annotations.Param;
import org.springframework.web.bind.annotation.GetMapping; import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController; import org.springframework.web.bind.annotation.RestController;
...@@ -25,13 +25,13 @@ import org.springframework.web.bind.annotation.RestController; ...@@ -25,13 +25,13 @@ import org.springframework.web.bind.annotation.RestController;
@Slf4j @Slf4j
@Tag(name = "读取实时数据") @Tag(name = "读取实时数据")
@RestController @RestController
@RequestMapping(value = "/getdata") @RequestMapping(value = "/api/charging/realtime")
@ResponseResultBody @ResponseResultBody
public class GetDataController extends BaseController { public class GetDataController extends BaseController {
@Operation(summary = "读取实时监测数据", description = "读取实时监测数据") @Operation(summary = "读取实时监测数据", description = "读取实时监测数据")
@GetMapping("/realtime") @GetMapping("/get")
public R<Boolean> getRealTimeData(@Param("pileId") String pileId, @Param("gunNumber") String gunNumber) { public R<Boolean> getRealTimeData(@PathVariable("pileId") String pileId, @PathVariable("gunNumber") String gunNumber) {
log.info("读取实时监测数据,充电桩编号:{}", pileId); log.info("读取实时监测数据,充电桩编号:{}", pileId);
log.info("读取实时监测数据,枪号:{}", gunNumber); log.info("读取实时监测数据,枪号:{}", gunNumber);
RealTimeReq req = new RealTimeReq(); RealTimeReq req = new RealTimeReq();
......
...@@ -27,8 +27,8 @@ public class UploadRealTimeRspHandler implements TcpHandler<UploadRealtimeDataRs ...@@ -27,8 +27,8 @@ public class UploadRealTimeRspHandler implements TcpHandler<UploadRealtimeDataRs
log.info("实时监测数据为空"); log.info("实时监测数据为空");
return null; return null;
} }
uploadRealTimeData(notify.getData());
log.info("实时监测数据:{}", data); log.info("实时监测数据:{}", data);
uploadRealTimeData(notify.getData());
return null; return null;
} }
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!