From 9df8787ac23ef6949d6f4afccd3fb0701a0f1bc6 Mon Sep 17 00:00:00 2001 From: hurui <177768073@qq.com> Date: Mon, 11 Oct 2021 20:51:13 +0800 Subject: [PATCH] =?UTF-8?q?=E6=8F=90=E4=BA=A4=E4=BB=A3=E7=A0=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- hai-cweb/src/test/common/test.java | 31 +++++++++++++++++++++++++----- 1 file changed, 26 insertions(+), 5 deletions(-) diff --git a/hai-cweb/src/test/common/test.java b/hai-cweb/src/test/common/test.java index dafbac71..d88c1ee4 100644 --- a/hai-cweb/src/test/common/test.java +++ b/hai-cweb/src/test/common/test.java @@ -7,11 +7,8 @@ import com.hai.common.QRCodeGenerator; import com.hai.common.utils.DateUtil; import com.hai.common.utils.HttpsUtils; import com.hai.common.utils.IDGenerator; -import com.hai.entity.HighCouponCode; -import com.hai.entity.SecRegion; -import com.hai.service.CommonService; -import com.hai.service.HighCouponCodeService; -import com.hai.service.HighMerchantStoreService; +import com.hai.entity.*; +import com.hai.service.*; import org.junit.Test; import org.junit.runner.RunWith; import org.springframework.boot.test.context.SpringBootTest; @@ -37,6 +34,30 @@ import java.util.*; @WebAppConfiguration public class test { + @Resource + private HighUserService highUserService; + + @Resource + private HighDiscountUserRelService highDiscountUserRelService; + + @Resource + private HighDiscountAgentCodeService highDiscountAgentCodeService; + + @Test + public void test(){ + +/* List codeList = highDiscountAgentCodeService.getDiscountCodeByDiscountAgentId(55L); + + List userList = highUserService.getUserList(); + + int num = 0; + for (HighUser user : userList) { + // 领取优惠券 + highDiscountUserRelService.receiveDiscount(user.getId(), codeList.get(num).getId()); + num++; + }*/ + } + public static void main(String[] args) {