更新对新增工单非空的判断
This commit is contained in:
parent
85f39ca8d9
commit
2a1438ada8
@ -91,7 +91,7 @@ public class WorkOrderServiceImpl implements WorkOrderService {
|
||||
orderMapper.insertSelective(domain);
|
||||
|
||||
// 上传文件
|
||||
if(!domain.getQuestionImgList().isEmpty()){
|
||||
if(domain.getQuestionImgList() != null && !domain.getQuestionImgList().isEmpty()){
|
||||
for(XhpcWorkOrderImageDomain imageDomain : domain.getQuestionImgList()){
|
||||
imageDomain.setOrderId(domain.getWorkOrderId());
|
||||
imageDomain.setType(Short.valueOf("1"));
|
||||
@ -101,7 +101,7 @@ public class WorkOrderServiceImpl implements WorkOrderService {
|
||||
}
|
||||
|
||||
// 绑定人员
|
||||
if(!domain.getUserList().isEmpty()){
|
||||
if(domain.getUserList() != null && !domain.getUserList().isEmpty()){
|
||||
List<XhpcWorkOrderUserDomain> orderUserDomainList = new ArrayList<>();
|
||||
StringBuilder userIdList = new StringBuilder();
|
||||
for (XhpcWorkUserDomain userDomain: domain.getUserList()){
|
||||
@ -127,7 +127,7 @@ public class WorkOrderServiceImpl implements WorkOrderService {
|
||||
|
||||
List<Long> imageIds = imageMapper.selectImageIdByOrderIdAndType(domain.getWorkOrderId(), 1);
|
||||
|
||||
if(!domain.getQuestionImgList().isEmpty()){
|
||||
if(domain.getQuestionImgList() != null && !domain.getQuestionImgList().isEmpty()){
|
||||
for (XhpcWorkOrderImageDomain imageDomain: domain.getQuestionImgList()){
|
||||
if( imageDomain.getOrderImageId() == null || StringUtils.isEmpty(imageDomain.getOrderImageId().toString())){
|
||||
imageDomain.setOrderId(domain.getWorkOrderId());
|
||||
@ -145,7 +145,7 @@ public class WorkOrderServiceImpl implements WorkOrderService {
|
||||
}
|
||||
}
|
||||
|
||||
if(!domain.getUserList().isEmpty()){
|
||||
if(domain.getUserList() != null && !domain.getUserList().isEmpty()){
|
||||
// 更新处理人
|
||||
StringBuilder userIdList = new StringBuilder();
|
||||
orderMapper.deleteOrderUserByOrderId(domain.getWorkOrderId());
|
||||
|
||||
@ -148,7 +148,7 @@ public class RealtimeDataLogic implements ServiceLogic {
|
||||
cacheOrder.put("totalMoney", cacheRealtimeData.getAmountCharged() / 10000.0);
|
||||
cacheOrder.put("realtimeDataList", realtimeDataList);
|
||||
R r1 = pileOrderService.pileRimeOrder(orderNo);
|
||||
if (r1 == null || (r1.getMsg()!=null && r1.getMsg().contains("无效订单")) || r1.getCode() >=500) {
|
||||
if (r1 == null || (r1.getMsg()!=null && r1.getMsg().contains("无效订单")) || (r1.getCode() >=500 && r1.getCode() != 3886)) {
|
||||
chargingController.stopInvalidOrder(orderNo);
|
||||
} else {
|
||||
Integer vul = (Integer) cachePile.get("voltageUpperLimits");
|
||||
@ -177,6 +177,13 @@ public class RealtimeDataLogic implements ServiceLogic {
|
||||
}
|
||||
}
|
||||
}
|
||||
Integer chargingDegree = cacheRealtimeData.getChargingDegree();
|
||||
Integer amountCharged =cacheRealtimeData.getAmountCharged();
|
||||
if(chargingDegree < 10000 && amountCharged > 200000){
|
||||
// 充电度数小于1,并且,充电金额大于10
|
||||
R r = chargingController.stopCharging(pileNo, gunId, default_version);
|
||||
}
|
||||
|
||||
if (balance < 50000) {
|
||||
String alerted = (String) cacheOrder.get("lt5alerted");
|
||||
String tel = (String) cacheOrder.get("tel");
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user