From bff603b970001cc4ed1c7000599eda9403408cf7 Mon Sep 17 00:00:00 2001 From: wangh <9483> Date: Sat, 13 Jan 2024 15:04:45 +0800 Subject: [PATCH] no message --- fuintAdmin/src/views/member/userInfo.vue | 5 +- .../impl/IntegralOrdersServiceImpl.java | 2 +- .../impl/CardValueRecordServiceImpl.java | 49 +++++++++++++++++++ 3 files changed, 53 insertions(+), 3 deletions(-) diff --git a/fuintAdmin/src/views/member/userInfo.vue b/fuintAdmin/src/views/member/userInfo.vue index 7df24b14b..379976508 100644 --- a/fuintAdmin/src/views/member/userInfo.vue +++ b/fuintAdmin/src/views/member/userInfo.vue @@ -1170,6 +1170,7 @@ export default { this.cardValueForm.royaltyType = change.royaltyType this.cardValueForm.percentageCommissions = change.percentageCommissions this.cardValueForm.amountCommission = change.amountCommission + this.cardValueForm.cardValueId = change.id // this.cardValueForm.rechargeBalance // 计算员工提成金额 @@ -1384,13 +1385,14 @@ export default { let file = {} // 拿到金额 file = this.cardValueList[index] - + console.log("file",file) this.realyPayBills = file.rechargeBalance this.cardValueForm.rechargeBalance = file.rechargeBalance this.cardValueForm.bidBalance = file.bidBalance this.cardValueForm.points = file.points this.cardValueForm.giftBalance = file.giftBalance this.cardValueForm.growthValue = file.growthValue + this.cardValueForm.cardValueId = file.id this.cardValueForm.amount = null this.cardValueForm.royaltyType = file.royaltyType @@ -1427,7 +1429,6 @@ export default { this.cardFuelDieselForm.incomeLitres = file.incomeLitres this.cardFuelDieselForm.lockupPrice = file.lockupPrice this.cardFuelDieselForm.cardFuelId = file.id - // this.realyPayBills = file.rechargeBalance }, diff --git a/fuintBackend/fuint-application/src/main/java/com/fuint/business/integral/service/impl/IntegralOrdersServiceImpl.java b/fuintBackend/fuint-application/src/main/java/com/fuint/business/integral/service/impl/IntegralOrdersServiceImpl.java index f1126b09f..f9890ce04 100644 --- a/fuintBackend/fuint-application/src/main/java/com/fuint/business/integral/service/impl/IntegralOrdersServiceImpl.java +++ b/fuintBackend/fuint-application/src/main/java/com/fuint/business/integral/service/impl/IntegralOrdersServiceImpl.java @@ -216,6 +216,7 @@ public class IntegralOrdersServiceImpl implements IntegralOrdersService { integralOrders.setOrderNumber(orderNo); integralOrders.setStatus(status); integralOrders.setOrderType("1"); // 设置交易类型 + integralOrders.setChainStoreId(nowAccountInfo.getChainStoreId()); // 设置交易类型 } @@ -356,7 +357,6 @@ public class IntegralOrdersServiceImpl implements IntegralOrdersService { cardExchangeRecordService.addCardExchangeRecord(cardExchangeRecord); }else if (integralGift.getGiftType().equals("优惠券")) { // 优惠卷处理 - integralGift.getCouponId(); CardFavorableRecord cardFavorableRecord = new CardFavorableRecord(); cardFavorableRecord.setCardFavorableId(integralGift.getCouponId()); cardFavorableRecord.setStoreId(integralOrders.getStoreId()); diff --git a/fuintBackend/fuint-application/src/main/java/com/fuint/business/marketingActivity/cardValue/service/impl/CardValueRecordServiceImpl.java b/fuintBackend/fuint-application/src/main/java/com/fuint/business/marketingActivity/cardValue/service/impl/CardValueRecordServiceImpl.java index 36eb38852..d003e24f9 100644 --- a/fuintBackend/fuint-application/src/main/java/com/fuint/business/marketingActivity/cardValue/service/impl/CardValueRecordServiceImpl.java +++ b/fuintBackend/fuint-application/src/main/java/com/fuint/business/marketingActivity/cardValue/service/impl/CardValueRecordServiceImpl.java @@ -28,8 +28,10 @@ import com.fuint.business.marketingActivity.cardFavorable.service.CardFavorableR import com.fuint.business.marketingActivity.cardFavorable.service.CardFavorableService; import com.fuint.business.marketingActivity.cardValue.dto.CardValueRecordDTO; import com.fuint.business.marketingActivity.cardValue.entity.CardValueChild; +import com.fuint.business.marketingActivity.cardValue.mapper.CardValueChildMapper; import com.fuint.business.marketingActivity.cardValue.mapper.CardValueRecordMapper; import com.fuint.business.marketingActivity.cardValue.entity.CardValueRecord; +import com.fuint.business.marketingActivity.cardValue.service.CardValueChildService; import com.fuint.business.marketingActivity.cardValue.service.CardValueRecordService; import com.fuint.business.marketingActivity.cardValue.service.CardValueService; import com.fuint.business.marketingActivity.cardValue.vo.CardValueVO; @@ -407,7 +409,11 @@ public class CardValueRecordServiceImpl extends ServiceImpl lambdaQueryWrapper = new LambdaQueryWrapper(); + lambdaQueryWrapper.eq(CardValueChild::getCardValueId,cardValueRecord.getCardValueId()); + List cardValueChildren = cardValueChildMapper.selectList(lambdaQueryWrapper); + for (CardValueChild cardValueChild : cardValueChildren) { + try{ + if ("1".equals(cardValueChild.getActiveGift())){ + //优惠券 + CardFavorableRecord cardFavorableRecord = new CardFavorableRecord(); + cardFavorableRecord.setCardFavorableId(cardValueChild.getVouchersId()); + cardFavorableRecord.setStoreId(cardValueRecord.getStoreId()); + cardFavorableRecord.setMtUserId(cardValueRecord.getMtUserId()); + cardFavorableRecord.setName(ljUserVos.getName()); + cardFavorableRecord.setMobile(ljUserVos.getMobile()); + cardFavorableRecord.setStatus("0"); + cardFavorableRecord.setExchangeFrom("储值卡赠送"); + }else if("2".equals(cardValueChild.getActiveGift())) { + //兑换券 + CardExchangeRecord cardExchangeRecord = new CardExchangeRecord(); + cardExchangeRecord.setCardExchangeId(cardValueChild.getVouchersId()); + cardExchangeRecord.setStoreId(cardValueRecord.getStoreId()); + cardExchangeRecord.setMtUserId(cardValueRecord.getMtUserId()); + cardExchangeRecord.setName(ljUserVos.getName()); + cardExchangeRecord.setMobile(ljUserVos.getMobile()); + cardExchangeRecord.setPhoto(ljUserVos.getAvatar()); + if (ObjectUtil.isNotEmpty(ljStaff)) { + cardExchangeRecord.setMtStaffId(ljStaff.getId()); + cardExchangeRecord.setRealName(ljStaff.getRealName()); + cardExchangeRecord.setStaffMobile(ljStaff.getMobile()); + } + cardExchangeRecord.setStatus("0"); + cardExchangeRecord.setExchangeFrom("储值卡赠送"); + cardExchangeRecordService.addCardExchangeRecord(cardExchangeRecord); + } + }catch (Exception e) { + e.printStackTrace(); + continue; + } + + + } // 修改订单的处理状态 (避免二次执行) CardValueRecord updateCardValueRecord = new CardValueRecord(); updateCardValueRecord.setId(id);