|
@@ -1,95 +1,95 @@
|
|
|
-import cn.hutool.core.lang.Assert;
|
|
|
-import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
|
|
-import com.baomidou.mybatisplus.core.toolkit.CollectionUtils;
|
|
|
-import com.dayou.BaseApplication;
|
|
|
-import com.dayou.bo.LeaderRatioBO;
|
|
|
-import com.dayou.configuration.AsyncManager;
|
|
|
-import com.dayou.controller.ItemController;
|
|
|
-import com.dayou.dto.ItemDTO;
|
|
|
-import com.dayou.entity.BrokerageMarketerRatio;
|
|
|
-import com.dayou.entity.Customer;
|
|
|
-import com.dayou.entity.ItemBrokerageGeneral;
|
|
|
-import com.dayou.entity.UserTarget;
|
|
|
-import com.dayou.service.*;
|
|
|
-import com.dayou.service.impl.ItemBrokerageSequenceServiceImpl;
|
|
|
-import com.dayou.utils.Md5Utils;
|
|
|
-import com.dayou.vo.ItemStageVO;
|
|
|
-import com.dayou.vo.ItemStatVO;
|
|
|
-import com.google.common.cache.Cache;
|
|
|
-import com.google.common.cache.LoadingCache;
|
|
|
-import com.google.common.collect.Lists;
|
|
|
-import com.zaxxer.hikari.HikariDataSource;
|
|
|
-import lombok.extern.slf4j.Slf4j;
|
|
|
-import org.apache.commons.lang3.RandomUtils;
|
|
|
-import org.junit.Test;
|
|
|
-import org.junit.runner.RunWith;
|
|
|
-import org.springframework.beans.factory.annotation.Autowired;
|
|
|
-import org.springframework.boot.test.context.SpringBootTest;
|
|
|
-import org.springframework.context.ApplicationContext;
|
|
|
-import org.springframework.jdbc.core.JdbcTemplate;
|
|
|
-import org.springframework.scheduling.annotation.Scheduled;
|
|
|
-import org.springframework.test.context.junit4.SpringJUnit4ClassRunner;
|
|
|
-
|
|
|
-import java.math.BigDecimal;
|
|
|
-import java.util.*;
|
|
|
-import java.util.concurrent.ExecutionException;
|
|
|
-import java.util.function.Consumer;
|
|
|
-import java.util.function.Function;
|
|
|
-import java.util.function.Predicate;
|
|
|
-import java.util.function.ToDoubleFunction;
|
|
|
-import java.util.stream.Collectors;
|
|
|
-
|
|
|
-/**
|
|
|
- * 类说明:
|
|
|
- *
|
|
|
- * @author: wucl
|
|
|
- * @since: 2023/3/6
|
|
|
- * created with IntelliJ IDEA.
|
|
|
- */
|
|
|
-@Slf4j
|
|
|
-@SpringBootTest(classes = BaseApplication.class)
|
|
|
-@RunWith(SpringJUnit4ClassRunner.class)
|
|
|
-public class BrokerageTest {
|
|
|
-
|
|
|
- @Autowired
|
|
|
- private ITeamMemberService teamMemberService;
|
|
|
-
|
|
|
- @Autowired
|
|
|
- private IItemBrokerageGeneralService iItemBrokerageGeneralService;
|
|
|
-
|
|
|
- @Autowired
|
|
|
- private IItemStageService itemStageService;
|
|
|
-
|
|
|
- @Autowired
|
|
|
- private IItemBrokerageSequenceService itemBrokerageSequenceService;
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-// @Test
|
|
|
-// public void generalBatchBrokerage() throws ExecutionException {
|
|
|
-// ArrayList<Long> itemIds = Lists.newArrayList(
|
|
|
-// 320L
|
|
|
-// );
|
|
|
+//import cn.hutool.core.lang.Assert;
|
|
|
+//import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
|
|
+//import com.baomidou.mybatisplus.core.toolkit.CollectionUtils;
|
|
|
+//import com.dayou.BaseApplication;
|
|
|
+//import com.dayou.bo.LeaderRatioBO;
|
|
|
+//import com.dayou.configuration.AsyncManager;
|
|
|
+//import com.dayou.controller.ItemController;
|
|
|
+//import com.dayou.dto.ItemDTO;
|
|
|
+//import com.dayou.entity.BrokerageMarketerRatio;
|
|
|
+//import com.dayou.entity.Customer;
|
|
|
+//import com.dayou.entity.ItemBrokerageGeneral;
|
|
|
+//import com.dayou.entity.UserTarget;
|
|
|
+//import com.dayou.service.*;
|
|
|
+//import com.dayou.service.impl.ItemBrokerageSequenceServiceImpl;
|
|
|
+//import com.dayou.utils.Md5Utils;
|
|
|
+//import com.dayou.vo.ItemStageVO;
|
|
|
+//import com.dayou.vo.ItemStatVO;
|
|
|
+//import com.google.common.cache.Cache;
|
|
|
+//import com.google.common.cache.LoadingCache;
|
|
|
+//import com.google.common.collect.Lists;
|
|
|
+//import com.zaxxer.hikari.HikariDataSource;
|
|
|
+//import lombok.extern.slf4j.Slf4j;
|
|
|
+//import org.apache.commons.lang3.RandomUtils;
|
|
|
+//import org.junit.Test;
|
|
|
+//import org.junit.runner.RunWith;
|
|
|
+//import org.springframework.beans.factory.annotation.Autowired;
|
|
|
+//import org.springframework.boot.test.context.SpringBootTest;
|
|
|
+//import org.springframework.context.ApplicationContext;
|
|
|
+//import org.springframework.jdbc.core.JdbcTemplate;
|
|
|
+//import org.springframework.scheduling.annotation.Scheduled;
|
|
|
+//import org.springframework.test.context.junit4.SpringJUnit4ClassRunner;
|
|
|
//
|
|
|
-// for (Long itemId : itemIds){
|
|
|
-// iItemBrokerageGeneralService.addMarketerBrokerage(itemId);
|
|
|
-// List<ItemStageVO> itemStageVOS = itemStageService.listByItemId(itemId);
|
|
|
-// if (CollectionUtils.isNotEmpty(itemStageVOS)){
|
|
|
-// for (ItemStageVO itemStageVO :itemStageVOS){
|
|
|
-// if (itemStageVO!=null && itemStageVO.getId()!=null){
|
|
|
+//import java.math.BigDecimal;
|
|
|
+//import java.util.*;
|
|
|
+//import java.util.concurrent.ExecutionException;
|
|
|
+//import java.util.function.Consumer;
|
|
|
+//import java.util.function.Function;
|
|
|
+//import java.util.function.Predicate;
|
|
|
+//import java.util.function.ToDoubleFunction;
|
|
|
+//import java.util.stream.Collectors;
|
|
|
//
|
|
|
-// iItemBrokerageGeneralService.addParticipatorBrokerage(itemStageVO,itemStageVO.getId());
|
|
|
-// }
|
|
|
-// }
|
|
|
-// }
|
|
|
-// }
|
|
|
-// }
|
|
|
+///**
|
|
|
+// * 类说明:
|
|
|
+// *
|
|
|
+// * @author: wucl
|
|
|
+// * @since: 2023/3/6
|
|
|
+// * created with IntelliJ IDEA.
|
|
|
+// */
|
|
|
+//@Slf4j
|
|
|
+//@SpringBootTest(classes = BaseApplication.class)
|
|
|
+//@RunWith(SpringJUnit4ClassRunner.class)
|
|
|
+//public class BrokerageTest {
|
|
|
//
|
|
|
+// @Autowired
|
|
|
+// private ITeamMemberService teamMemberService;
|
|
|
//
|
|
|
-// @Test
|
|
|
-// public void settle(){
|
|
|
-// Boolean result = itemBrokerageSequenceService.doAbleItemBrokerageSettle();
|
|
|
-// //Boolean nonResult = itemBrokerageSequenceService.doNonMarketerAheadSettle();
|
|
|
-// Assert.isTrue(result);
|
|
|
-// }
|
|
|
-}
|
|
|
+// @Autowired
|
|
|
+// private IItemBrokerageGeneralService iItemBrokerageGeneralService;
|
|
|
+//
|
|
|
+// @Autowired
|
|
|
+// private IItemStageService itemStageService;
|
|
|
+//
|
|
|
+// @Autowired
|
|
|
+// private IItemBrokerageSequenceService itemBrokerageSequenceService;
|
|
|
+//
|
|
|
+//
|
|
|
+//
|
|
|
+//// @Test
|
|
|
+//// public void generalBatchBrokerage() throws ExecutionException {
|
|
|
+//// ArrayList<Long> itemIds = Lists.newArrayList(
|
|
|
+//// 320L
|
|
|
+//// );
|
|
|
+////
|
|
|
+//// for (Long itemId : itemIds){
|
|
|
+//// iItemBrokerageGeneralService.addMarketerBrokerage(itemId);
|
|
|
+//// List<ItemStageVO> itemStageVOS = itemStageService.listByItemId(itemId);
|
|
|
+//// if (CollectionUtils.isNotEmpty(itemStageVOS)){
|
|
|
+//// for (ItemStageVO itemStageVO :itemStageVOS){
|
|
|
+//// if (itemStageVO!=null && itemStageVO.getId()!=null){
|
|
|
+////
|
|
|
+//// iItemBrokerageGeneralService.addParticipatorBrokerage(itemStageVO,itemStageVO.getId());
|
|
|
+//// }
|
|
|
+//// }
|
|
|
+//// }
|
|
|
+//// }
|
|
|
+//// }
|
|
|
+////
|
|
|
+////
|
|
|
+//// @Test
|
|
|
+//// public void settle(){
|
|
|
+//// Boolean result = itemBrokerageSequenceService.doAbleItemBrokerageSettle();
|
|
|
+//// //Boolean nonResult = itemBrokerageSequenceService.doNonMarketerAheadSettle();
|
|
|
+//// Assert.isTrue(result);
|
|
|
+//// }
|
|
|
+//}
|