From ed7cde0f64b01e95e11d6f66d1f27b05cea84332 Mon Sep 17 00:00:00 2001 From: jiangqs <jiangqs> Date: 星期日, 09 七月 2023 18:13:00 +0800 Subject: [PATCH] 管理台bug和用户端 --- ruoyi-modules/ruoyi-member/src/main/java/com/ruoyi/member/service/impl/birthday/BirthdayCardServiceImpl.java | 15 +++++++++++---- 1 files changed, 11 insertions(+), 4 deletions(-) diff --git a/ruoyi-modules/ruoyi-member/src/main/java/com/ruoyi/member/service/impl/birthday/BirthdayCardServiceImpl.java b/ruoyi-modules/ruoyi-member/src/main/java/com/ruoyi/member/service/impl/birthday/BirthdayCardServiceImpl.java index 40fe121..5a04222 100644 --- a/ruoyi-modules/ruoyi-member/src/main/java/com/ruoyi/member/service/impl/birthday/BirthdayCardServiceImpl.java +++ b/ruoyi-modules/ruoyi-member/src/main/java/com/ruoyi/member/service/impl/birthday/BirthdayCardServiceImpl.java @@ -3,13 +3,14 @@ import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; import com.ruoyi.common.core.utils.bean.BeanUtils; +import com.ruoyi.common.core.utils.uuid.IdUtils; import com.ruoyi.member.domain.dto.MerBirthdayEditDto; import com.ruoyi.member.domain.dto.MgtBirthdayEditDto; import com.ruoyi.member.domain.dto.MgtBirthdayGetDto; import com.ruoyi.member.domain.dto.MgtBirthdayGiftDto; import com.ruoyi.member.domain.pojo.birthday.BirthdayCard; import com.ruoyi.member.domain.pojo.birthday.BirthdayGift; -import com.ruoyi.member.domain.pojo.member.MemberGiftRecord; +import com.ruoyi.system.api.domain.poji.member.MemberGiftRecord; import com.ruoyi.member.domain.vo.*; import com.ruoyi.member.mapper.birthday.BirthdayCardMapper; import com.ruoyi.member.service.birthday.BirthdayCardService; @@ -482,6 +483,7 @@ BigDecimal winningProbability; BigDecimal randomProbability; BirthdayGiftSendDto birthdayGiftSendDto; + String prizeId; String currentYear = String.valueOf(LocalDate.now().getYear()); // 获取平台生日卡信息 BirthdayCard plBirthdayCard = birthdayCardMapper.getPlatformBirthdayCard(shopId); @@ -499,6 +501,10 @@ memberGiftRecord = new MemberGiftRecord(); birthdayGiftSendDto = new BirthdayGiftSendDto(); BeanUtils.copyProperties(birthdayGift, memberGiftRecord); + prizeId = IdUtils.simpleUUID(); + memberGiftRecord.setPrizeId(prizeId); + memberGiftRecord.setDelFlag(0); + memberGiftRecord.setVerifyStatus(1); memberGiftRecord.setGiftFrom(1); memberGiftRecord.setGiftYear(currentYear); memberGiftRecord.setCreateTime(new Date()); @@ -564,6 +570,10 @@ memberGiftRecord = new MemberGiftRecord(); birthdayGiftSendDto = new BirthdayGiftSendDto(); BeanUtils.copyProperties(birthdayGift, memberGiftRecord); + prizeId = IdUtils.simpleUUID(); + memberGiftRecord.setPrizeId(prizeId); + memberGiftRecord.setDelFlag(0); + memberGiftRecord.setVerifyStatus(1); memberGiftRecord.setGiftFrom(2); memberGiftRecord.setShopId(shopId); memberGiftRecord.setGiftYear(currentYear); @@ -610,9 +620,6 @@ } } } - //发放奖品 - remoteOrderService.sendGoodsGift(sendGoodsList); - remoteCouponService.sendCouponGift(sendCouponList); //保存用户礼物记录 memberGiftRecordService.saveBatch(memberGiftRecordList); appBirthdayCardVo.setBirthdayGiftVoList(birthdayGiftVoList); -- Gitblit v1.7.1