This commit is contained in:
2023-04-18 16:46:56 +08:00
3 changed files with 31 additions and 34 deletions

View File

@@ -5,6 +5,7 @@ import com.jsowell.common.annotation.Anonymous;
import com.jsowell.common.core.controller.BaseController;
import com.jsowell.common.response.RestApiResponse;
import com.jsowell.pile.dto.QueryStationInfoDTO;
import com.jsowell.thirdparty.domain.StationStatsInfo;
import com.jsowell.thirdparty.service.LianLianService;
import com.jsowell.thirdparty.vo.LianLianPageResponse;
import org.apache.commons.collections4.CollectionUtils;
@@ -50,8 +51,8 @@ public class LianLianController extends BaseController {
}
/**
* 查询充电站状态信息
* @param dto
* 联联平台查询充电站状态信息
* @param StationIDs
* @return
*/
@PostMapping("/query_station_status")
@@ -71,4 +72,24 @@ public class LianLianController extends BaseController {
logger.info("联联平台查询充电站状态信息 result:{}", response);
return response;
}
/**
* 查询统计信息
* @param dto
* @return
*/
@PostMapping("/query_station_stats")
public RestApiResponse<?> query_station_stats(@RequestBody QueryStationInfoDTO dto) {
logger.info("联联平台查询统计信息 params :{}", JSONObject.toJSONString(dto));
RestApiResponse<?> response;
try {
StationStatsInfo stationStatsInfo = lianLianService.query_station_stats(dto);
response = new RestApiResponse<>(stationStatsInfo);
} catch (Exception e) {
logger.error("联联平台查询统计信息 error", e);
response = new RestApiResponse<>(e);
}
logger.info("联联平台查询统计信息 result :{}", response);
return response;
}
}