|
@@ -68,12 +68,15 @@ public class NoCarRecServiceImpl extends ServiceImpl<CustomerCarRecMapper,Custom
|
|
|
|
|
|
for(CardBindQueryListToBModel cardBindQueryListToBModel:cardBindQueryListToBResponses){
|
|
|
boolean has = false;
|
|
|
- for(CustomerCarRec customerCarRec1:customerCarRecs){
|
|
|
+ if(customerCarRecs != null && customerCarRecs.size()>0){
|
|
|
+ for(CustomerCarRec customerCarRec1:customerCarRecs){
|
|
|
+
|
|
|
+ if(cardBindQueryListToBModel.getCardId().equals(customerCarRec1.getEtcNum())){
|
|
|
+ has = true;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
|
|
|
- if(cardBindQueryListToBModel.getCardId().equals(customerCarRec1.getEtcNum())){
|
|
|
- has = true;
|
|
|
- }
|
|
|
- }
|
|
|
if(!has){
|
|
|
CustomerCarRec customerCarRecDb = new CustomerCarRec();
|
|
|
customerCarRecDb.setInterType(1);
|
|
@@ -90,6 +93,14 @@ public class NoCarRecServiceImpl extends ServiceImpl<CustomerCarRecMapper,Custom
|
|
|
}
|
|
|
|
|
|
}
|
|
|
+ }else{
|
|
|
+ //车牌下的卡都更新为注销
|
|
|
+ if(customerCarRecs!=null && customerCarRecs.size()>0){
|
|
|
+ customerCarRecs.forEach(customerCarRec1 -> {
|
|
|
+ customerCarRec1.setRecStatus(2);
|
|
|
+ customerCarRecMapper.updateETCByPrimaryKeySelective(customerCarRec1);
|
|
|
+ });
|
|
|
+ }
|
|
|
}
|
|
|
|
|
|
}
|