mirror of
https://codeup.aliyun.com/67c68d4e484ca2f0a13ac3c1/ydc/jsowell-charger-web.git
synced 2026-04-20 02:55:04 +08:00
Merge branch 'dev-new' into dev-new-rabbitmq
This commit is contained in:
@@ -7,6 +7,7 @@ import com.jsowell.common.enums.thirdparty.ThirdPartyReturnCodeEnum;
|
|||||||
import com.jsowell.common.exception.BusinessException;
|
import com.jsowell.common.exception.BusinessException;
|
||||||
import com.jsowell.common.response.RestApiResponse;
|
import com.jsowell.common.response.RestApiResponse;
|
||||||
import com.jsowell.pile.dto.QueryOperatorInfoDTO;
|
import com.jsowell.pile.dto.QueryOperatorInfoDTO;
|
||||||
|
import com.jsowell.pile.dto.QueryOrderDTO;
|
||||||
import com.jsowell.pile.dto.QueryStationInfoDTO;
|
import com.jsowell.pile.dto.QueryStationInfoDTO;
|
||||||
import com.jsowell.pile.thirdparty.CommonParamsDTO;
|
import com.jsowell.pile.thirdparty.CommonParamsDTO;
|
||||||
import com.jsowell.thirdparty.lianlian.common.CommonResult;
|
import com.jsowell.thirdparty.lianlian.common.CommonResult;
|
||||||
@@ -209,4 +210,13 @@ public class GuiZhouPlatformController extends ThirdPartyBaseController {
|
|||||||
return response;
|
return response;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@PostMapping("/tempPushHistoryOrderInfo")
|
||||||
|
public RestApiResponse<?> tempPushHistoryOrderInfo(@RequestBody QueryOrderDTO dto) {
|
||||||
|
RestApiResponse<?> response = null;
|
||||||
|
String result = platformLogic.pushOrderInfo(dto);
|
||||||
|
response = new RestApiResponse<>(result);
|
||||||
|
return response;
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
191
jsowell-admin/src/main/java/com/jsowell/api/thirdparty/XinYunPlatformController.java
vendored
Normal file
191
jsowell-admin/src/main/java/com/jsowell/api/thirdparty/XinYunPlatformController.java
vendored
Normal file
@@ -0,0 +1,191 @@
|
|||||||
|
package com.jsowell.api.thirdparty;
|
||||||
|
|
||||||
|
import com.alibaba.fastjson2.JSON;
|
||||||
|
import com.jsowell.common.annotation.Anonymous;
|
||||||
|
import com.jsowell.common.enums.thirdparty.ThirdPartyReturnCodeEnum;
|
||||||
|
import com.jsowell.common.enums.thirdparty.ThirdPlatformTypeEnum;
|
||||||
|
import com.jsowell.pile.dto.QueryEquipChargeStatusDTO;
|
||||||
|
import com.jsowell.pile.dto.QueryStationInfoDTO;
|
||||||
|
import com.jsowell.pile.thirdparty.CommonParamsDTO;
|
||||||
|
import com.jsowell.thirdparty.lianlian.common.CommonResult;
|
||||||
|
import com.jsowell.thirdparty.platform.service.ThirdPartyPlatformService;
|
||||||
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.beans.factory.annotation.Qualifier;
|
||||||
|
import org.springframework.web.bind.annotation.PostMapping;
|
||||||
|
import org.springframework.web.bind.annotation.RequestBody;
|
||||||
|
import org.springframework.web.bind.annotation.RequestMapping;
|
||||||
|
import org.springframework.web.bind.annotation.RestController;
|
||||||
|
|
||||||
|
import javax.servlet.http.HttpServletRequest;
|
||||||
|
import java.util.Map;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新运平台Controller
|
||||||
|
*
|
||||||
|
* @author Lemon
|
||||||
|
* @Date 2025/1/11 15:55:34
|
||||||
|
*/
|
||||||
|
@Anonymous
|
||||||
|
@RestController
|
||||||
|
@RequestMapping("/xinyun")
|
||||||
|
public class XinYunPlatformController extends ThirdPartyBaseController{
|
||||||
|
private final String platformName = "新运平台";
|
||||||
|
|
||||||
|
private final String platformType = ThirdPlatformTypeEnum.XIN_YUN_PLATFORM.getTypeCode();
|
||||||
|
|
||||||
|
@Autowired
|
||||||
|
@Qualifier("xinYunPlatformServiceImpl")
|
||||||
|
private ThirdPartyPlatformService platformLogic;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* getToken
|
||||||
|
*/
|
||||||
|
@PostMapping("/v1/query_token")
|
||||||
|
public CommonResult<?> queryToken(@RequestBody CommonParamsDTO dto) {
|
||||||
|
// logger.info("{}-请求令牌 params:{}", platformName, JSON.toJSONString(dto));
|
||||||
|
try {
|
||||||
|
Map<String, String> map = platformLogic.queryToken(dto);
|
||||||
|
logger.info("{}-请求令牌, params:{}, result:{}", platformName, JSON.toJSONString(dto), JSON.toJSONString(map));
|
||||||
|
return CommonResult.success(Integer.parseInt(map.get("Ret")), map.get("Msg"), map.get("Data"), map.get("Sig"));
|
||||||
|
} catch (Exception e) {
|
||||||
|
logger.error("{}-获取token接口, 异常, params:{}", platformName, JSON.toJSONString(dto), e);
|
||||||
|
return CommonResult.failed("获取token发生异常");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询充电站信息
|
||||||
|
* query_stations_info
|
||||||
|
*/
|
||||||
|
@PostMapping("/v1/query_stations_info")
|
||||||
|
public CommonResult<?> query_stations_info(HttpServletRequest request, @RequestBody CommonParamsDTO dto) {
|
||||||
|
logger.info("{}-查询充电站信息 params:{}", platformName, JSON.toJSONString(dto));
|
||||||
|
try {
|
||||||
|
// 校验令牌
|
||||||
|
if (!verifyToken(request.getHeader("Authorization"))) {
|
||||||
|
// 校验失败
|
||||||
|
return CommonResult.failed(ThirdPartyReturnCodeEnum.TOKEN_ERROR);
|
||||||
|
}
|
||||||
|
dto.setPlatformType(platformType);
|
||||||
|
|
||||||
|
// 校验签名
|
||||||
|
if (!verifySignature(dto)) {
|
||||||
|
// 签名错误
|
||||||
|
return CommonResult.failed(ThirdPartyReturnCodeEnum.SIGN_ERROR);
|
||||||
|
}
|
||||||
|
|
||||||
|
// 解析入参
|
||||||
|
QueryStationInfoDTO queryStationInfoDTO = parseParamsDTO(dto, QueryStationInfoDTO.class);
|
||||||
|
|
||||||
|
// 执行逻辑
|
||||||
|
Map<String, String> map = platformLogic.queryStationsInfo(queryStationInfoDTO);
|
||||||
|
|
||||||
|
return CommonResult.success(Integer.parseInt(map.get("Ret")), map.get("Msg"), map.get("Data"), map.get("Sig"));
|
||||||
|
} catch (Exception e) {
|
||||||
|
logger.info("{}-查询充电站信息 error:", platformName, e);
|
||||||
|
}
|
||||||
|
return CommonResult.failed("查询充电站信息发生异常");
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询充电站状态信息
|
||||||
|
* query_station_status
|
||||||
|
*/
|
||||||
|
@PostMapping("/v1/query_station_status")
|
||||||
|
public CommonResult<?> queryStationStatus(HttpServletRequest request, @RequestBody CommonParamsDTO dto) {
|
||||||
|
logger.info("{}-查询充电站状态信息 params:{}", platformName, JSON.toJSONString(dto));
|
||||||
|
try {
|
||||||
|
// 校验令牌
|
||||||
|
if (!verifyToken(request.getHeader("Authorization"))) {
|
||||||
|
// 校验失败
|
||||||
|
return CommonResult.failed(ThirdPartyReturnCodeEnum.TOKEN_ERROR);
|
||||||
|
}
|
||||||
|
dto.setPlatformType(platformType);
|
||||||
|
|
||||||
|
// 校验签名
|
||||||
|
if (!verifySignature(dto)) {
|
||||||
|
// 签名错误
|
||||||
|
return CommonResult.failed(ThirdPartyReturnCodeEnum.SIGN_ERROR);
|
||||||
|
}
|
||||||
|
|
||||||
|
// 解析入参
|
||||||
|
QueryStationInfoDTO queryStationInfoDTO = parseParamsDTO(dto, QueryStationInfoDTO.class);
|
||||||
|
|
||||||
|
// 执行逻辑
|
||||||
|
Map<String, String> map = platformLogic.queryStationStatus(queryStationInfoDTO);
|
||||||
|
|
||||||
|
return CommonResult.success(Integer.parseInt(map.get("Ret")), map.get("Msg"), map.get("Data"), map.get("Sig"));
|
||||||
|
} catch (Exception e) {
|
||||||
|
logger.error("{}-查询充电站状态信息 error:", platformName, e);
|
||||||
|
}
|
||||||
|
return CommonResult.failed("查询充电站状态信息发生异常");
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询充电站统计信息
|
||||||
|
* query_station_stats
|
||||||
|
*/
|
||||||
|
@PostMapping("/v1/query_station_stats")
|
||||||
|
public CommonResult<?> queryStationStats(HttpServletRequest request, @RequestBody CommonParamsDTO dto) {
|
||||||
|
logger.info("{}-查询充电站统计信息 params:{}", platformName, JSON.toJSONString(dto));
|
||||||
|
try {
|
||||||
|
// 校验令牌
|
||||||
|
if (!verifyToken(request.getHeader("Authorization"))) {
|
||||||
|
// 校验失败
|
||||||
|
return CommonResult.failed(ThirdPartyReturnCodeEnum.TOKEN_ERROR);
|
||||||
|
}
|
||||||
|
dto.setPlatformType(platformType);
|
||||||
|
|
||||||
|
// 校验签名
|
||||||
|
if (!verifySignature(dto)) {
|
||||||
|
// 签名错误
|
||||||
|
return CommonResult.failed(ThirdPartyReturnCodeEnum.SIGN_ERROR);
|
||||||
|
}
|
||||||
|
|
||||||
|
// 解析入参
|
||||||
|
QueryStationInfoDTO queryStationInfoDTO = parseParamsDTO(dto, QueryStationInfoDTO.class);
|
||||||
|
|
||||||
|
// 执行逻辑
|
||||||
|
Map<String, String> map = platformLogic.queryStationStats(queryStationInfoDTO);
|
||||||
|
|
||||||
|
return CommonResult.success(Integer.parseInt(map.get("Ret")), map.get("Msg"), map.get("Data"), map.get("Sig"));
|
||||||
|
} catch (Exception e) {
|
||||||
|
logger.error("{}-查询充电站统计信息 error:", platformName, e);
|
||||||
|
}
|
||||||
|
return CommonResult.failed("查询充电站统计信息发生异常");
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询充电状态
|
||||||
|
* query_equip_charge_status
|
||||||
|
*/
|
||||||
|
@PostMapping("/v1/query_equip_charge_status")
|
||||||
|
public CommonResult<?> queryEquipChargeStatus(HttpServletRequest request, @RequestBody CommonParamsDTO dto) {
|
||||||
|
logger.info("{}-查询充电状态 params:{}", platformName, JSON.toJSONString(dto));
|
||||||
|
try {
|
||||||
|
// 校验令牌
|
||||||
|
if (!verifyToken(request.getHeader("Authorization"))) {
|
||||||
|
// 校验失败
|
||||||
|
return CommonResult.failed(ThirdPartyReturnCodeEnum.TOKEN_ERROR);
|
||||||
|
}
|
||||||
|
dto.setPlatformType(platformType);
|
||||||
|
|
||||||
|
// 校验签名
|
||||||
|
if (!verifySignature(dto)) {
|
||||||
|
// 签名错误
|
||||||
|
return CommonResult.failed(ThirdPartyReturnCodeEnum.SIGN_ERROR);
|
||||||
|
}
|
||||||
|
|
||||||
|
// 解析入参
|
||||||
|
QueryEquipChargeStatusDTO queryEquipChargeStatusDTO = parseParamsDTO(dto, QueryEquipChargeStatusDTO.class);
|
||||||
|
|
||||||
|
// 执行逻辑
|
||||||
|
Map<String, String> map = platformLogic.queryEquipChargeStatus(queryEquipChargeStatusDTO);
|
||||||
|
|
||||||
|
return CommonResult.success(Integer.parseInt(map.get("Ret")), map.get("Msg"), map.get("Data"), map.get("Sig"));
|
||||||
|
} catch (Exception e) {
|
||||||
|
logger.error("{}-查询充电状态 error:", platformName, e);
|
||||||
|
}
|
||||||
|
return CommonResult.failed("查询充电状态发生异常");
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -30,7 +30,7 @@ public enum ThirdPlatformTypeEnum {
|
|||||||
NAN_RUI_PLATFORM("19", "南瑞平台", ""),
|
NAN_RUI_PLATFORM("19", "南瑞平台", ""),
|
||||||
GUANG_XI_PLATFORM("20", "广西平台", "450000000"),
|
GUANG_XI_PLATFORM("20", "广西平台", "450000000"),
|
||||||
|
|
||||||
XIN_YUN_PLATFORM("21", "新运平台", ""),
|
XIN_YUN_PLATFORM("21", "新运平台", "MADKXL8FX"),
|
||||||
;
|
;
|
||||||
|
|
||||||
private String typeCode;
|
private String typeCode;
|
||||||
|
|||||||
@@ -10,6 +10,7 @@ import com.jsowell.common.core.domain.vo.AuthorizedDeptVO;
|
|||||||
import com.jsowell.common.core.domain.ykc.*;
|
import com.jsowell.common.core.domain.ykc.*;
|
||||||
import com.jsowell.common.core.redis.RedisCache;
|
import com.jsowell.common.core.redis.RedisCache;
|
||||||
import com.jsowell.common.enums.DelFlagEnum;
|
import com.jsowell.common.enums.DelFlagEnum;
|
||||||
|
import com.jsowell.common.enums.lianlian.LianLianPileStatusEnum;
|
||||||
import com.jsowell.common.enums.ykc.PileConnectorDataBaseStatusEnum;
|
import com.jsowell.common.enums.ykc.PileConnectorDataBaseStatusEnum;
|
||||||
import com.jsowell.common.enums.ykc.PileConnectorStatusEnum;
|
import com.jsowell.common.enums.ykc.PileConnectorStatusEnum;
|
||||||
import com.jsowell.common.enums.ykc.PileStatusEnum;
|
import com.jsowell.common.enums.ykc.PileStatusEnum;
|
||||||
@@ -1242,7 +1243,18 @@ public class PileBasicInfoServiceImpl implements PileBasicInfoService {
|
|||||||
equipmentInfo.setEquipmentType(Integer.valueOf(pileDetailInfoVO.getSpeedType()));
|
equipmentInfo.setEquipmentType(Integer.valueOf(pileDetailInfoVO.getSpeedType()));
|
||||||
equipmentInfo.setEquipmentModel(pileDetailInfoVO.getModelName());
|
equipmentInfo.setEquipmentModel(pileDetailInfoVO.getModelName());
|
||||||
|
|
||||||
equipmentInfo.setEquipmentStatus(Integer.valueOf(pileDetailInfoVO.getPileStatus()));
|
String pileStatus = pileDetailInfoVO.getPileStatus();
|
||||||
|
if (StringUtils.equals(PileStatusEnum.ON_LINE.getValue(), pileStatus)) {
|
||||||
|
// 1-在线
|
||||||
|
pileStatus = LianLianPileStatusEnum.NORMAL.getCode();
|
||||||
|
} else if (StringUtils.equals(PileStatusEnum.OFF_LINE.getValue(), pileStatus)) {
|
||||||
|
// 2-离线
|
||||||
|
pileStatus = LianLianPileStatusEnum.CLOSE_OFFLINE.getCode();
|
||||||
|
} else if (StringUtils.equals(PileStatusEnum.FAULT.getValue(), pileStatus)) {
|
||||||
|
// 3-故障
|
||||||
|
pileStatus = LianLianPileStatusEnum.UNDER_MAINTENANCE.getCode();
|
||||||
|
}
|
||||||
|
equipmentInfo.setEquipmentStatus(Integer.valueOf(pileStatus));
|
||||||
equipmentInfo.setEquipmentPower(new BigDecimal(pileDetailInfoVO.getRatedPower()).setScale(1, BigDecimal.ROUND_HALF_UP));
|
equipmentInfo.setEquipmentPower(new BigDecimal(pileDetailInfoVO.getRatedPower()).setScale(1, BigDecimal.ROUND_HALF_UP));
|
||||||
equipmentInfo.setNewNationalStandard(1);
|
equipmentInfo.setNewNationalStandard(1);
|
||||||
equipmentInfo.setVinFlag(1);
|
equipmentInfo.setVinFlag(1);
|
||||||
|
|||||||
@@ -21,6 +21,7 @@ import com.jsowell.common.util.*;
|
|||||||
import com.jsowell.pile.domain.*;
|
import com.jsowell.pile.domain.*;
|
||||||
import com.jsowell.pile.dto.QueryConnectorListDTO;
|
import com.jsowell.pile.dto.QueryConnectorListDTO;
|
||||||
import com.jsowell.pile.dto.QueryOperatorInfoDTO;
|
import com.jsowell.pile.dto.QueryOperatorInfoDTO;
|
||||||
|
import com.jsowell.pile.dto.QueryOrderDTO;
|
||||||
import com.jsowell.pile.dto.QueryStationInfoDTO;
|
import com.jsowell.pile.dto.QueryStationInfoDTO;
|
||||||
import com.jsowell.pile.service.*;
|
import com.jsowell.pile.service.*;
|
||||||
import com.jsowell.pile.thirdparty.CommonParamsDTO;
|
import com.jsowell.pile.thirdparty.CommonParamsDTO;
|
||||||
@@ -446,15 +447,17 @@ public class GuiZhouPlatformServiceImpl implements ThirdPartyPlatformService {
|
|||||||
StationStatusInfo stationStatusInfo = new StationStatusInfo();
|
StationStatusInfo stationStatusInfo = new StationStatusInfo();
|
||||||
|
|
||||||
PileStationVO stationInfo = pileStationInfoService.getStationInfo(stationId);
|
PileStationVO stationInfo = pileStationInfoService.getStationInfo(stationId);
|
||||||
|
PileMerchantInfoVO pileMerchantInfoVO = pileMerchantInfoService.queryMerchantInfoByStationId(String.valueOf(stationInfo.getId()));
|
||||||
|
String organizationCode = pileMerchantInfoVO.getOrganizationCode();
|
||||||
|
|
||||||
stationStatusInfo.setOperatorId(Constants.OPERATORID_JIANG_SU);
|
stationStatusInfo.setOperatorId(Constants.OPERATORID_JIANG_SU);
|
||||||
stationStatusInfo.setEquipmentOwnerId(ThirdPartyPlatformUtils.extractEquipmentOwnerID(stationInfo.getOrganizationCode()));
|
stationStatusInfo.setEquipmentOwnerId(ThirdPartyPlatformUtils.extractEquipmentOwnerID(organizationCode));
|
||||||
stationStatusInfo.setStationId(stationId);
|
stationStatusInfo.setStationId(stationId);
|
||||||
ConnectorStatusInfo connectorStatusInfo;
|
ConnectorStatusInfo connectorStatusInfo;
|
||||||
for (ConnectorInfoVO connectorInfoVO : voList) {
|
for (ConnectorInfoVO connectorInfoVO : voList) {
|
||||||
connectorStatusInfo = ConnectorStatusInfo.builder()
|
connectorStatusInfo = ConnectorStatusInfo.builder()
|
||||||
.operatorId(Constants.OPERATORID_JIANG_SU)
|
.operatorId(Constants.OPERATORID_JIANG_SU)
|
||||||
.equipmentOwnerId(ThirdPartyPlatformUtils.extractEquipmentOwnerID(stationInfo.getOrganizationCode()))
|
.equipmentOwnerId(ThirdPartyPlatformUtils.extractEquipmentOwnerID(organizationCode))
|
||||||
.stationId(connectorInfoVO.getStationId())
|
.stationId(connectorInfoVO.getStationId())
|
||||||
.equipmentId(connectorInfoVO.getPileSn())
|
.equipmentId(connectorInfoVO.getPileSn())
|
||||||
.connectorID(connectorInfoVO.getPileConnectorCode())
|
.connectorID(connectorInfoVO.getPileConnectorCode())
|
||||||
@@ -544,7 +547,8 @@ public class GuiZhouPlatformServiceImpl implements ThirdPartyPlatformService {
|
|||||||
String urlAddress = guiZhouPlatformSecretInfo.getTheirUrlPrefix();
|
String urlAddress = guiZhouPlatformSecretInfo.getTheirUrlPrefix();
|
||||||
// 查询站点信息
|
// 查询站点信息
|
||||||
PileStationVO stationInfo = pileStationInfoService.getStationInfo(orderInfo.getStationId());
|
PileStationVO stationInfo = pileStationInfoService.getStationInfo(orderInfo.getStationId());
|
||||||
String organizationCode = stationInfo.getOrganizationCode();
|
PileMerchantInfoVO pileMerchantInfoVO = pileMerchantInfoService.queryMerchantInfoByStationId(String.valueOf(stationInfo.getId()));
|
||||||
|
String organizationCode = pileMerchantInfoVO.getOrganizationCode();
|
||||||
|
|
||||||
// 查询枪口实时状态
|
// 查询枪口实时状态
|
||||||
List<RealTimeMonitorData> chargingRealTimeData = orderBasicInfoService.getChargingRealTimeData(orderInfo.getTransactionCode());
|
List<RealTimeMonitorData> chargingRealTimeData = orderBasicInfoService.getChargingRealTimeData(orderInfo.getTransactionCode());
|
||||||
@@ -689,7 +693,7 @@ public class GuiZhouPlatformServiceImpl implements ThirdPartyPlatformService {
|
|||||||
|
|
||||||
ChargeOrderInfo orderInfo = transformChargeOrderInfo(orderBasicInfo, orderDetail);
|
ChargeOrderInfo orderInfo = transformChargeOrderInfo(orderBasicInfo, orderDetail);
|
||||||
|
|
||||||
List<BillingPriceVO> billingList = pileBillingTemplateService.queryBillingPrice(orderBasicInfo.getStationId());
|
// List<BillingPriceVO> billingList = pileBillingTemplateService.queryBillingPrice(orderBasicInfo.getStationId());
|
||||||
// 先将list按照 尖、峰、平、谷 时段排序
|
// 先将list按照 尖、峰、平、谷 时段排序
|
||||||
// List<BillingPriceVO> collect = billingList.stream().sorted(Comparator.comparing(BillingPriceVO::getTimeType)).collect(Collectors.toList());
|
// List<BillingPriceVO> collect = billingList.stream().sorted(Comparator.comparing(BillingPriceVO::getTimeType)).collect(Collectors.toList());
|
||||||
// 再循环该list,拼装对应的充电价格、费率
|
// 再循环该list,拼装对应的充电价格、费率
|
||||||
@@ -707,6 +711,28 @@ public class GuiZhouPlatformServiceImpl implements ThirdPartyPlatformService {
|
|||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public String pushOrderInfo(QueryOrderDTO dto) {
|
||||||
|
// ThirdPartySecretInfoVO thirdPartySecretInfoVO = getGuiZhouPlatformSecretInfo();
|
||||||
|
|
||||||
|
// 根据站点id, 开始时间,结束时间查询出所有的订单信息
|
||||||
|
// List<OrderListVO> orderListVOS = orderBasicInfoService.selectOrderBasicInfoList(dto);
|
||||||
|
List<String> orderCodes = orderBasicInfoService.tempGetOrderCodes(dto);
|
||||||
|
if (CollectionUtils.isEmpty(orderCodes)) {
|
||||||
|
return "订单信息为空";
|
||||||
|
}
|
||||||
|
// List<String> orderCodeList = orderListVOS.stream().map(OrderListVO::getOrderCode).collect(Collectors.toList());
|
||||||
|
for (String orderCode : orderCodes) {
|
||||||
|
try {
|
||||||
|
String result = notificationChargeOrderInfoHistory(orderCode);
|
||||||
|
logger.info("订单:{} 推送结果:{}", orderCode, result);
|
||||||
|
}catch (Exception e) {
|
||||||
|
logger.error("订单:{} 推送error, ", orderCode, e);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return "Success";
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 推送充换电站用能统计信息 supervise_notification_operation_stats_info
|
* 推送充换电站用能统计信息 supervise_notification_operation_stats_info
|
||||||
*
|
*
|
||||||
@@ -812,7 +838,8 @@ public class GuiZhouPlatformServiceImpl implements ThirdPartyPlatformService {
|
|||||||
}
|
}
|
||||||
|
|
||||||
PileStationVO stationInfo = pileStationInfoService.getStationInfo(stationId);
|
PileStationVO stationInfo = pileStationInfoService.getStationInfo(stationId);
|
||||||
String organizationCode = stationInfo.getOrganizationCode();
|
PileMerchantInfoVO pileMerchantInfoVO = pileMerchantInfoService.queryMerchantInfoByStationId(String.valueOf(stationInfo.getId()));
|
||||||
|
String organizationCode = pileMerchantInfoVO.getOrganizationCode();
|
||||||
|
|
||||||
// 创建对象
|
// 创建对象
|
||||||
String startTime = DateUtils.getYesterdayStr();
|
String startTime = DateUtils.getYesterdayStr();
|
||||||
@@ -995,7 +1022,8 @@ public class GuiZhouPlatformServiceImpl implements ThirdPartyPlatformService {
|
|||||||
*/
|
*/
|
||||||
private ChargeOrderInfo transformChargeOrderInfo(OrderBasicInfo orderBasicInfo, OrderDetail orderDetail) {
|
private ChargeOrderInfo transformChargeOrderInfo(OrderBasicInfo orderBasicInfo, OrderDetail orderDetail) {
|
||||||
PileStationVO stationInfo = pileStationInfoService.getStationInfo(orderBasicInfo.getStationId());
|
PileStationVO stationInfo = pileStationInfoService.getStationInfo(orderBasicInfo.getStationId());
|
||||||
String organizationCode = stationInfo.getOrganizationCode();
|
PileMerchantInfoVO pileMerchantInfoVO = pileMerchantInfoService.queryMerchantInfoByStationId(String.valueOf(stationInfo.getId()));
|
||||||
|
String organizationCode = pileMerchantInfoVO.getOrganizationCode();
|
||||||
|
|
||||||
ChargeOrderInfo chargeOrderInfo = ChargeOrderInfo.builder()
|
ChargeOrderInfo chargeOrderInfo = ChargeOrderInfo.builder()
|
||||||
.operatorID(Constants.OPERATORID_JIANG_SU)
|
.operatorID(Constants.OPERATORID_JIANG_SU)
|
||||||
|
|||||||
Reference in New Issue
Block a user