This commit is contained in:
cun-nan 2024-01-19 13:08:30 +08:00
parent 3ef9ad404b
commit bd213aa77b

View File

@ -487,7 +487,7 @@ public class ActiveExchangeServiceImpl implements ActiveExchangeService {
for (ActiveDiscountPayVO activeDiscountPayVO : activeDiscountVOList) { for (ActiveDiscountPayVO activeDiscountPayVO : activeDiscountVOList) {
if (activeDiscountPayVO.getParticipationCondition().equals("1")){ if (activeDiscountPayVO.getParticipationCondition().equals("1")){
for (CardFavorableRecordVO cardFavorableRecordVO : canUserCardFavorableList) { for (CardFavorableRecordVO cardFavorableRecordVO : canUserCardFavorableList) {
if(cardFavorableRecordVO.getType().equals("2") && !cardFavorableRecordVO.getExclusiveFunction().equals("0")){ if(cardFavorableRecordVO.getExclusiveFunction().equals("2") && !cardFavorableRecordVO.getExclusiveFunction().equals("0")){
ActiveDiscountPayVO activeDiscountPayVO1 = new ActiveDiscountPayVO(); ActiveDiscountPayVO activeDiscountPayVO1 = new ActiveDiscountPayVO();
BeanUtils.copyProperties(activeDiscountPayVO,activeDiscountPayVO1); BeanUtils.copyProperties(activeDiscountPayVO,activeDiscountPayVO1);
activeDiscountPayVO1.setCouponId(cardFavorableRecordVO.getId()); activeDiscountPayVO1.setCouponId(cardFavorableRecordVO.getId());
@ -500,11 +500,12 @@ public class ActiveExchangeServiceImpl implements ActiveExchangeService {
activeDiscountPayVO1.setCardFavorableAmount(BigDecimal.valueOf(cardFavorableRecordVO.getDiscountAmount())); activeDiscountPayVO1.setCardFavorableAmount(BigDecimal.valueOf(cardFavorableRecordVO.getDiscountAmount()));
activeDiscountPayVO1.setCardFavorableInfo(cardFavorableRecordVO.getCardFavorableName()); activeDiscountPayVO1.setCardFavorableInfo(cardFavorableRecordVO.getCardFavorableName());
cardAndDisPays.add(activeDiscountPayVO1); cardAndDisPays.add(activeDiscountPayVO1);
}else if( !cardFavorableRecordVO.getExclusiveFunction().equals("0")){ }else if( cardFavorableRecordVO.getExclusiveFunction().equals("0")){
ActiveDiscountPayVO activeDiscountPayVO1 = new ActiveDiscountPayVO(); ActiveDiscountPayVO activeDiscountPayVO1 = new ActiveDiscountPayVO();
BeanUtils.copyProperties(activeDiscountPayVO,activeDiscountPayVO1); BeanUtils.copyProperties(activeDiscountPayVO,activeDiscountPayVO1);
String[] split = cardFavorableRecordVO.getOilType().split(","); String[] split = cardFavorableRecordVO.getOilType().split(",");
if(paymentActiveDTO.getOilId().equals(split)){ for (String oilId : split) {
if((paymentActiveDTO.getOilId()).toString().equals(oilId)){
activeDiscountPayVO1.setCouponId(cardFavorableRecordVO.getId()); activeDiscountPayVO1.setCouponId(cardFavorableRecordVO.getId());
double discountAmount = cardFavorableRecordVO.getDiscountAmount(); double discountAmount = cardFavorableRecordVO.getDiscountAmount();
activeDiscountPayVO1.setActiveDiscount(activeDiscountPayVO1.getDiscount()); activeDiscountPayVO1.setActiveDiscount(activeDiscountPayVO1.getDiscount());
@ -516,6 +517,8 @@ public class ActiveExchangeServiceImpl implements ActiveExchangeService {
cardAndDisPays.add(activeDiscountPayVO1); cardAndDisPays.add(activeDiscountPayVO1);
} }
} }
}
} }
} }
@ -536,11 +539,12 @@ public class ActiveExchangeServiceImpl implements ActiveExchangeService {
activeDiscountPayVO1.setCardFavorableAmount(BigDecimal.valueOf(cardFavorableRecordVO.getDiscountAmount())); activeDiscountPayVO1.setCardFavorableAmount(BigDecimal.valueOf(cardFavorableRecordVO.getDiscountAmount()));
activeDiscountPayVO1.setCardFavorableInfo(cardFavorableRecordVO.getCardFavorableName()); activeDiscountPayVO1.setCardFavorableInfo(cardFavorableRecordVO.getCardFavorableName());
cardAndComPays.add(activeDiscountPayVO1); cardAndComPays.add(activeDiscountPayVO1);
}else if (!cardFavorableRecordVO.getExclusiveFunction().equals("0")){ }else if (cardFavorableRecordVO.getExclusiveFunction().equals("0")){
ActiveDiscountPayVO activeDiscountPayVO1 = new ActiveDiscountPayVO(); ActiveDiscountPayVO activeDiscountPayVO1 = new ActiveDiscountPayVO();
BeanUtils.copyProperties(activeDiscountPayVO,activeDiscountPayVO1); BeanUtils.copyProperties(activeDiscountPayVO,activeDiscountPayVO1);
String[] split = cardFavorableRecordVO.getOilType().split(","); String[] split = cardFavorableRecordVO.getOilType().split(",");
if(paymentActiveDTO.getOilId().equals(split)){ for (String oilId : split) {
if((paymentActiveDTO.getOilId()).toString().equals(oilId)){
activeDiscountPayVO1.setCouponId(cardFavorableRecordVO.getId()); activeDiscountPayVO1.setCouponId(cardFavorableRecordVO.getId());
double discountAmount = cardFavorableRecordVO.getDiscountAmount(); double discountAmount = cardFavorableRecordVO.getDiscountAmount();
activeDiscountPayVO1.setActiveDiscount(activeDiscountPayVO1.getDiscount()); activeDiscountPayVO1.setActiveDiscount(activeDiscountPayVO1.getDiscount());
@ -552,6 +556,8 @@ public class ActiveExchangeServiceImpl implements ActiveExchangeService {
cardAndComPays.add(activeDiscountPayVO1); cardAndComPays.add(activeDiscountPayVO1);
} }
} }
}
} }
} }
} }