From d42435fe2441269affeff46d6c3eeb640f85348f Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?=E9=BD=90=E5=A4=A9=E5=A4=A7=E5=9C=A3?= <17615834396@163.com>
Date: Sat, 27 Jan 2024 15:45:10 +0800
Subject: [PATCH] =?UTF-8?q?=E9=A2=86=E5=88=B8bug?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
.../EventMarketing/Writeoffrecords/index.vue | 8 +-
.../EventMarketing/activeRecommend/index.vue | 6 +-
.../cardExchangeRecord/index.vue | 9 +-
.../entity/ActiveConsumptionChild.java | 162 +-----------------
.../impl/ActiveExchangeServiceImpl.java | 42 ++++-
.../ActiveNewlywedsRecordsServiceImpl.java | 2 +-
.../impl/CardExchangeRecordServiceImpl.java | 7 +-
7 files changed, 64 insertions(+), 172 deletions(-)
diff --git a/fuintAdmin/src/views/EventMarketing/Writeoffrecords/index.vue b/fuintAdmin/src/views/EventMarketing/Writeoffrecords/index.vue
index 72d283a14..d436bc395 100644
--- a/fuintAdmin/src/views/EventMarketing/Writeoffrecords/index.vue
+++ b/fuintAdmin/src/views/EventMarketing/Writeoffrecords/index.vue
@@ -62,10 +62,14 @@
-
+
+
+
-
+
diff --git a/fuintAdmin/src/views/EventMarketing/activeRecommend/index.vue b/fuintAdmin/src/views/EventMarketing/activeRecommend/index.vue
index 8c04e7099..a4857d409 100644
--- a/fuintAdmin/src/views/EventMarketing/activeRecommend/index.vue
+++ b/fuintAdmin/src/views/EventMarketing/activeRecommend/index.vue
@@ -269,20 +269,20 @@
参数二维码
-
+
进行中
- 待生效
+
已结束
diff --git a/fuintAdmin/src/views/EventMarketing/cardExchangeRecord/index.vue b/fuintAdmin/src/views/EventMarketing/cardExchangeRecord/index.vue
index d00523afe..a40ea1b8e 100644
--- a/fuintAdmin/src/views/EventMarketing/cardExchangeRecord/index.vue
+++ b/fuintAdmin/src/views/EventMarketing/cardExchangeRecord/index.vue
@@ -49,16 +49,19 @@
-
+
+
-
+
diff --git a/fuintBackend/fuint-application/src/main/java/com/fuint/business/marketingActivity/activeConsumption/entity/ActiveConsumptionChild.java b/fuintBackend/fuint-application/src/main/java/com/fuint/business/marketingActivity/activeConsumption/entity/ActiveConsumptionChild.java
index 46b56ed51..2e9c71ccc 100644
--- a/fuintBackend/fuint-application/src/main/java/com/fuint/business/marketingActivity/activeConsumption/entity/ActiveConsumptionChild.java
+++ b/fuintBackend/fuint-application/src/main/java/com/fuint/business/marketingActivity/activeConsumption/entity/ActiveConsumptionChild.java
@@ -3,9 +3,11 @@ package com.fuint.business.marketingActivity.activeConsumption.entity;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.fasterxml.jackson.annotation.JsonFormat;
+import lombok.Data;
import java.util.Date;
+@Data
public class ActiveConsumptionChild {
private static final long serialVersionUID = 231279479087493223L;
/**
@@ -83,164 +85,4 @@ public class ActiveConsumptionChild {
*/
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss" , timezone = "GMT+8")
private Date updateTime;
-
- public String getTimeType() {
- return timeType;
- }
-
- public void setTimeType(String timeType) {
- this.timeType = timeType;
- }
-
- public Integer getValidityZero() {
- return validityZero;
- }
-
- public void setValidityZero(Integer validityZero) {
- this.validityZero = validityZero;
- }
-
- public Integer getValidityOne() {
- return validityOne;
- }
-
- public void setValidityOne(Integer validityOne) {
- this.validityOne = validityOne;
- }
-
- public Integer getValidityTwo() {
- return validityTwo;
- }
-
- public void setValidityTwo(Integer validityTwo) {
- this.validityTwo = validityTwo;
- }
-
- public Integer getId() {
- return id;
- }
-
- public void setId(Integer id) {
- this.id = id;
- }
-
- public Integer getActiveConsumptionId() {
- return activeConsumptionId;
- }
-
- public void setActiveConsumptionId(Integer activeConsumptionId) {
- this.activeConsumptionId = activeConsumptionId;
- }
-
- public String getActiveGift() {
- return activeGift;
- }
-
- public void setActiveGift(String activeGift) {
- this.activeGift = activeGift;
- }
-
- public Integer getGoodsIds() {
- return goodsIds;
- }
-
- public void setGoodsIds(Integer goodsIds) {
- this.goodsIds = goodsIds;
- }
-
- public String getGoodsName() {
- return goodsName;
- }
-
- public void setGoodsName(String goodsName) {
- this.goodsName = goodsName;
- }
-
- public Integer getGoodsTotal() {
- return goodsTotal;
- }
-
- public void setGoodsTotal(Integer goodsTotal) {
- this.goodsTotal = goodsTotal;
- }
-
- public Integer getVouchersId() {
- return vouchersId;
- }
-
- public void setVouchersId(Integer vouchersId) {
- this.vouchersId = vouchersId;
- }
-
- public String getGiftCardName() {
- return giftCardName;
- }
-
- public void setGiftCardName(String giftCardName) {
- this.giftCardName = giftCardName;
- }
-
- public String getGiftCardType() {
- return giftCardType;
- }
-
- public void setGiftCardType(String giftCardType) {
- this.giftCardType = giftCardType;
- }
-
- public String getGiftCardDetail() {
- return giftCardDetail;
- }
-
- public void setGiftCardDetail(String giftCardDetail) {
- this.giftCardDetail = giftCardDetail;
- }
-
- public Integer getGiftCardTime() {
- return giftCardTime;
- }
-
- public void setGiftCardTime(Integer giftCardTime) {
- this.giftCardTime = giftCardTime;
- }
-
- public Integer getGiftCardTotal() {
- return giftCardTotal;
- }
-
- public void setGiftCardTotal(Integer giftCardTotal) {
- this.giftCardTotal = giftCardTotal;
- }
-
- public String getCreateBy() {
- return createBy;
- }
-
- public void setCreateBy(String createBy) {
- this.createBy = createBy;
- }
-
- public Date getCreateTime() {
- return createTime;
- }
-
- public void setCreateTime(Date createTime) {
- this.createTime = createTime;
- }
-
- public String getUpdateBy() {
- return updateBy;
- }
-
- public void setUpdateBy(String updateBy) {
- this.updateBy = updateBy;
- }
-
- public Date getUpdateTime() {
- return updateTime;
- }
-
- public void setUpdateTime(Date updateTime) {
- this.updateTime = updateTime;
- }
}
diff --git a/fuintBackend/fuint-application/src/main/java/com/fuint/business/marketingActivity/activeExchange/service/impl/ActiveExchangeServiceImpl.java b/fuintBackend/fuint-application/src/main/java/com/fuint/business/marketingActivity/activeExchange/service/impl/ActiveExchangeServiceImpl.java
index 8fb87c9ca..8b3b2288b 100644
--- a/fuintBackend/fuint-application/src/main/java/com/fuint/business/marketingActivity/activeExchange/service/impl/ActiveExchangeServiceImpl.java
+++ b/fuintBackend/fuint-application/src/main/java/com/fuint/business/marketingActivity/activeExchange/service/impl/ActiveExchangeServiceImpl.java
@@ -7,6 +7,8 @@ import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.core.toolkit.CollectionUtils;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.fuint.business.marketingActivity.activeConsumption.entity.ActiveConsumption;
+import com.fuint.business.marketingActivity.activeConsumption.entity.ActiveConsumptionChild;
+import com.fuint.business.marketingActivity.activeConsumption.service.ActiveConsumptionChildService;
import com.fuint.business.marketingActivity.activeConsumption.service.ActiveConsumptionService;
import com.fuint.business.marketingActivity.activeConsumption.vo.ActiveConsumptionAppletVO;
import com.fuint.business.marketingActivity.activeDiscount.entity.ActiveDiscount;
@@ -123,6 +125,8 @@ public class ActiveExchangeServiceImpl implements ActiveExchangeService {
@Autowired
@Lazy
private ChainStoreConfigService chainStoreConfigService;
+ @Resource
+ private ActiveConsumptionChildService activeConsumptionChildService;
/**
* 分页查询所有
* @param
@@ -861,8 +865,42 @@ public class ActiveExchangeServiceImpl implements ActiveExchangeService {
}
userBalanceService.save(userBalance1);
}
+ //查询改活动下的卡券列表
+ LambdaQueryWrapper queryWrapper = new LambdaQueryWrapper<>();
+ queryWrapper.eq(ActiveConsumptionChild::getActiveConsumptionId,activeConsumptionVO.getActiveId());
+ List list = activeConsumptionChildService.list(queryWrapper);
+ if (ObjectUtils.isNotEmpty(list)){
+
+ for (ActiveConsumptionChild activeConsumptionChild : list) {
+ if (ObjectUtils.isNotEmpty(activeConsumptionChild) && activeConsumptionChild.getActiveGift().equals("1")){
+ CardFavorableRecord cardFavorableRecord = new CardFavorableRecord();
+ cardFavorableRecord.setCardFavorableId(activeConsumptionChild.getVouchersId());
+ cardFavorableRecord.setStoreId(storeId1);
+ cardFavorableRecord.setMtUserId(TokenUtil.getNowAccountInfo().getId());
+ cardFavorableRecord.setName(ljUserVo.getName());
+ cardFavorableRecord.setMobile(ljUserVo.getMobile());
+ cardFavorableRecord.setStatus("0");
+ cardFavorableRecord.setExchangeFrom("充值送券");
+ cardFavorableRecordService.addCardFavorableRecord(cardFavorableRecord);
+ //兑换券
+ }else if (ObjectUtils.isNotEmpty(activeConsumptionChild) && activeConsumptionChild.getActiveGift().equals("2")){
+ CardExchangeRecord cardExchangeRecord = new CardExchangeRecord();
+ cardExchangeRecord.setCardExchangeId(activeConsumptionChild.getVouchersId());
+ cardExchangeRecord.setStoreId(storeId1);
+ cardExchangeRecord.setMtUserId(ljUserVo.getId());
+ cardExchangeRecord.setName(ljUserVo.getName());
+ cardExchangeRecord.setMobile(ljUserVo.getMobile());
+ cardExchangeRecord.setPhoto(ljUserVo.getAvatar());
+ cardExchangeRecord.setStatus("0");
+ cardExchangeRecord.setExchangeFrom("充值送券");
+ cardExchangeRecordService.addCardExchangeRecord(cardExchangeRecord);
+ }
+ }
+ }
+
//优惠券
- if (StringUtils.isNotEmpty(activeConsumptionVO.getActiveGift()) && activeConsumptionVO.getActiveGift().equals("1")){
+ //if (StringUtils.isNotEmpty(activeConsumptionVO.getActiveGift()) && activeConsumptionVO.getActiveGift().equals("1")){
+ /*if (ObjectUtils.isNotEmpty(list) && activeConsumptionVO.getActiveGift().equals("1")){
CardFavorableRecord cardFavorableRecord = new CardFavorableRecord();
cardFavorableRecord.setCardFavorableId(activeConsumptionVO.getVouchersId());
cardFavorableRecord.setStoreId(storeId1);
@@ -884,7 +922,7 @@ public class ActiveExchangeServiceImpl implements ActiveExchangeService {
cardExchangeRecord.setStatus("0");
cardExchangeRecord.setExchangeFrom("充值送券");
cardExchangeRecordService.addCardExchangeRecord(cardExchangeRecord);
- }
+ }*/
}
}
}
diff --git a/fuintBackend/fuint-application/src/main/java/com/fuint/business/marketingActivity/activeNewlyweds/service/impl/ActiveNewlywedsRecordsServiceImpl.java b/fuintBackend/fuint-application/src/main/java/com/fuint/business/marketingActivity/activeNewlyweds/service/impl/ActiveNewlywedsRecordsServiceImpl.java
index 5575dcf89..10b295a73 100644
--- a/fuintBackend/fuint-application/src/main/java/com/fuint/business/marketingActivity/activeNewlyweds/service/impl/ActiveNewlywedsRecordsServiceImpl.java
+++ b/fuintBackend/fuint-application/src/main/java/com/fuint/business/marketingActivity/activeNewlyweds/service/impl/ActiveNewlywedsRecordsServiceImpl.java
@@ -97,7 +97,7 @@ public class ActiveNewlywedsRecordsServiceImpl extends ServiceImpl