0C协议更新,下发费率响应
This commit is contained in:
parent
52d84b8579
commit
fff1786306
@ -39,13 +39,21 @@ public class RateModelConfigReplyDataLogic implements ServiceLogic {
|
|||||||
|
|
||||||
String result = FAIL;
|
String result = FAIL;
|
||||||
if (HEX_01.equals(configResult)) {
|
if (HEX_01.equals(configResult)) {
|
||||||
// 确定设置成功的rateModelId 可能涉及协议修改
|
|
||||||
final String pkey = "pile:".concat(pileRateModelConfigReplyData.getPileNo());
|
final String pkey = "pile:".concat(pileRateModelConfigReplyData.getPileNo());
|
||||||
Map<String, Object> cachePile = REDIS.getCacheMap(pkey);
|
Map<String, Object> cachePile = REDIS.getCacheMap(pkey);
|
||||||
ChargingStationDto cacheStation = REDIS.getCacheObject("station:".concat(cachePile.get("stationId").toString()));
|
ChargingStationDto cacheStation = REDIS.getCacheObject("station:".concat(cachePile.get("stationId").toString()));
|
||||||
cachePile.put("rateModelId", cacheStation.getRateModelId());
|
String version = (String) cachePile.get("version");
|
||||||
|
if (!"0A".equals(version) && !"0B".equals(version)) {
|
||||||
|
Long stationRateModelId = cacheStation.getRateModelId();
|
||||||
|
if (stationRateModelId.equals(pileRateModelConfigReplyData.getRateModelId())) {
|
||||||
|
cachePile.put("rateModelId", cacheStation.getRateModelId());
|
||||||
|
result = OK;
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
cachePile.put("rateModelId", cacheStation.getRateModelId());
|
||||||
|
result = OK;
|
||||||
|
}
|
||||||
REDIS.setCacheMap(pkey, cachePile);
|
REDIS.setCacheMap(pkey, cachePile);
|
||||||
result = OK;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
String remark = "充电桩收到计费模型应答";
|
String remark = "充电桩收到计费模型应答";
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user