避免第三方查询未启动的订单报错
This commit is contained in:
parent
0cb71ab537
commit
338ebbaebb
@ -53,8 +53,12 @@ public class QueryEquipChargeStatusController {
|
|||||||
}
|
}
|
||||||
String internalOrderNum = etOrderMapping.getXhOrderNo();
|
String internalOrderNum = etOrderMapping.getXhOrderNo();
|
||||||
Map<String, Object> cacheOrder = REDIS.getCacheMap("order:" + internalOrderNum);
|
Map<String, Object> cacheOrder = REDIS.getCacheMap("order:" + internalOrderNum);
|
||||||
|
if (cacheOrder == null) {
|
||||||
|
response.setRet(EvcsConst.RET_FAIL);
|
||||||
|
response.setMsg("Order cache data not found");
|
||||||
|
} else {
|
||||||
String orderStatus = (String) cacheOrder.get("status");
|
String orderStatus = (String) cacheOrder.get("status");
|
||||||
int startChargeSeqStat = 0;
|
int startChargeSeqStat;
|
||||||
if (orderStatus == null) {
|
if (orderStatus == null) {
|
||||||
startChargeSeqStat = 5;
|
startChargeSeqStat = 5;
|
||||||
} else switch (orderStatus) {
|
} else switch (orderStatus) {
|
||||||
@ -130,6 +134,7 @@ public class QueryEquipChargeStatusController {
|
|||||||
response.setRet(EvcsConst.RET_SUCC);
|
response.setRet(EvcsConst.RET_SUCC);
|
||||||
response.setData(JSONUtil.toJSONString(equipChargeStatus));
|
response.setData(JSONUtil.toJSONString(equipChargeStatus));
|
||||||
response.setMsg("success");
|
response.setMsg("success");
|
||||||
|
}
|
||||||
return response;
|
return response;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user