|
|
@@ -66,9 +66,9 @@ public class ReleaseUserTask {
|
|
|
* 客户释放
|
|
|
*
|
|
|
*/
|
|
|
-// @Scheduled(cron = "0 23 9 * * ?")
|
|
|
+ @Scheduled(cron = "0 30 16 * * ?")
|
|
|
// @RequestMapping("/open/test")
|
|
|
- @Scheduled(cron = "0 0 1 * * ?")
|
|
|
+// @Scheduled(cron = "0 0 1 * * ?")
|
|
|
public void startTask() {
|
|
|
try {
|
|
|
List<User> userList = userService.selectUserByRoleName("营销员", "营销经理");
|
|
|
@@ -241,13 +241,17 @@ public class ReleaseUserTask {
|
|
|
if (StringUtils.isNotBlank(u.getId())&&!AFTConstants.CAOJIN_AID.equals(u.getId())) {
|
|
|
// 获取30天释放 释放以锁定表与user_mid最后跟进取时间
|
|
|
List<LockingReleaseBo> userTmpList = customerService.selectWaitReleaseCustomer(u.getId());
|
|
|
- customerService.pushReleaseLog(userTmpList, 0);
|
|
|
+ customerService.pushReleaseLog(userTmpList);
|
|
|
addUserNotice(userTmpList);
|
|
|
if (!userTmpList.isEmpty()) {
|
|
|
- //私有的交给原来的处理锁与客户,签单的另外处理
|
|
|
- List<LockingReleaseBo> collect = userTmpList.stream().filter(e -> e.getShareType() == 0).collect(Collectors.toList());
|
|
|
+ //30天私有和270天签单业务释放不改变
|
|
|
+ List<LockingReleaseBo> collect = userTmpList.stream().filter(e ->
|
|
|
+ (e.getShareType() == 0&& e.getType()==0)||e.getType()==1
|
|
|
+ ).collect(Collectors.toList());
|
|
|
lockUserList.addAll(collect);
|
|
|
- List<LockingReleaseBo> collect2 = userTmpList.stream().filter(e -> e.getShareType() == 2).collect(Collectors.toList());
|
|
|
+ //30天签单单独只释放签签单
|
|
|
+ List<LockingReleaseBo> collect2 = userTmpList.stream().filter(e ->
|
|
|
+ e.getShareType() == 2&& e.getType()==0).collect(Collectors.toList());
|
|
|
lockUserList2.addAll(collect2);
|
|
|
}
|
|
|
}
|
|
|
@@ -269,6 +273,7 @@ public class ReleaseUserTask {
|
|
|
if (!lockUserList2.isEmpty()) {
|
|
|
for (int i = 0; i < lockUserList2.size(); i++) {
|
|
|
newList.add(lockUserList2.get(i));
|
|
|
+ System.out.println(lockUserList2.get(i).getUserName());
|
|
|
if (pointsDataLimit == newList.size() || i == lockUserList.size() - 1) {
|
|
|
userService.updateUserShareType(newList);
|
|
|
newList.clear();
|