From fe879975a3e8a0a1aa280fb839e02d159bfbcff8 Mon Sep 17 00:00:00 2001
From: admin <weikou2014>
Date: 星期二, 27 八月 2019 18:04:38 +0800
Subject: [PATCH] 金币任务多次获取bug修改

---
 fanli/src/main/java/com/yeshi/fanli/service/impl/integral/IntegralExchangeServiceImpl.java |    9 ++++++++-
 1 files changed, 8 insertions(+), 1 deletions(-)

diff --git a/fanli/src/main/java/com/yeshi/fanli/service/impl/integral/IntegralExchangeServiceImpl.java b/fanli/src/main/java/com/yeshi/fanli/service/impl/integral/IntegralExchangeServiceImpl.java
index cec6d33..11d78ec 100644
--- a/fanli/src/main/java/com/yeshi/fanli/service/impl/integral/IntegralExchangeServiceImpl.java
+++ b/fanli/src/main/java/com/yeshi/fanli/service/impl/integral/IntegralExchangeServiceImpl.java
@@ -218,12 +218,13 @@
 		String thing = "";
 		String thingNum = "";
 		int couponNews = 0;
+		boolean once = false; // 鍏戞崲涓�娆℃槸鍚︽秷澶�
 		try {
 			if (ExchangeTypeEnum.freeCouponBuy == type) {
 				thing = "鑷喘鍏嶅崟鍒�";
 				thingNum = "1寮�";
 				userSystemCouponService.exchangeCoupon(uid, type.name(), UserSystemCoupon.SOURCE_EXCHANGE, null);
-				
+				once = true; 
 				couponNews = 1;
 			} else if (ExchangeTypeEnum.freeCouponGive == type) {
 				thing = "璧犻�佸厤鍗曞埜";
@@ -242,6 +243,9 @@
 				if(codePublishRecordService.countValidRecord(uid) > 0)
 					throw new IntegralExchangeException(1, "涓夊ぉ涔嬪唴涓嶅彲閲嶅鍏戞崲");
 				codePublishRecordService.publishInviteCode(uid);
+				
+				exchange.setNeedJump(true);
+				exchange.setBtnName("鍘绘煡鐪�");
 			} else if (ExchangeTypeEnum.taoLiJin == type) {
 				thing = "鎺ㄥ箍绾㈠寘";
 				thingNum = exchange.getAmount() + "鍏�";
@@ -317,6 +321,9 @@
 				}
 			});
 			
+			if (once) // 鍏戞崲涔嬪悗娑堝け
+				exchange = null;
+			
 			return exchange;
 		} catch (Exception e) {
 			LogHelper.errorDetailInfo(e);

--
Gitblit v1.8.0