mirror of
https://codeup.aliyun.com/67c68d4e484ca2f0a13ac3c1/ydc/jsowell-charger-web.git
synced 2026-04-22 03:55:17 +08:00
add 联联平台 请求启动充电 接口
This commit is contained in:
@@ -3,16 +3,14 @@ package com.jsowell.lianlian;
|
||||
import com.alibaba.fastjson2.JSONObject;
|
||||
import com.jsowell.common.annotation.Anonymous;
|
||||
import com.jsowell.common.core.controller.BaseController;
|
||||
import com.jsowell.common.exception.BusinessException;
|
||||
import com.jsowell.common.response.RestApiResponse;
|
||||
import com.jsowell.pile.dto.QueryEquipmentDTO;
|
||||
import com.jsowell.pile.dto.QueryStartChargeDTO;
|
||||
import com.jsowell.pile.dto.QueryStationInfoDTO;
|
||||
import com.jsowell.thirdparty.domain.StationStatsInfo;
|
||||
import com.jsowell.thirdparty.service.LianLianService;
|
||||
import com.jsowell.thirdparty.vo.EquipmentAuthVO;
|
||||
import com.jsowell.thirdparty.vo.LianLianPageResponse;
|
||||
import com.jsowell.thirdparty.vo.QueryChargingStatusVO;
|
||||
import com.jsowell.thirdparty.vo.QueryStopChargeVO;
|
||||
import com.jsowell.thirdparty.vo.*;
|
||||
import org.apache.commons.collections4.CollectionUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
@@ -118,6 +116,28 @@ public class LianLianController extends BaseController {
|
||||
return response;
|
||||
}
|
||||
|
||||
/**
|
||||
* 请求启动充电
|
||||
* @param dto
|
||||
* @return
|
||||
*/
|
||||
@PostMapping("/query_start_charge")
|
||||
public RestApiResponse<?> query_start_charge(@RequestBody QueryStartChargeDTO dto) {
|
||||
logger.info("联联平台请求启动充电 params :{}", JSONObject.toJSONString(dto));
|
||||
RestApiResponse<?> response;
|
||||
try {
|
||||
QueryStartChargeVO queryStartChargeVO = lianLianService.query_start_charge(dto);
|
||||
response = new RestApiResponse<>(queryStartChargeVO);
|
||||
}catch (BusinessException e) {
|
||||
logger.error("联联平台请求启动充电 error",e);
|
||||
response = new RestApiResponse<>(e.getCode(), e.getMessage());
|
||||
} catch (Exception e) {
|
||||
logger.error("联联平台请求启动充电 error", e);
|
||||
response = new RestApiResponse<>(e);
|
||||
}
|
||||
logger.info("联联平台请求启动充电 result :{}", response);
|
||||
return response;
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询充电状态
|
||||
|
||||
Reference in New Issue
Block a user