账号修改状态

master
bynt 3 years ago
parent b616034e0d
commit 836bd9b14c

@ -1,24 +1,19 @@
package com.hchbox.task; package com.hchbox.task;
import cn.hutool.core.collection.CollUtil;
import cn.hutool.core.date.DateUtil; import cn.hutool.core.date.DateUtil;
import com.hchbox.constant.DefaultNumberConstants; import com.hchbox.constant.DefaultNumberConstants;
import com.hchbox.entity.master.SellerAccount; import com.hchbox.entity.master.SellerAccount;
import com.hchbox.repository.master.SellerAccountRepository; import com.hchbox.repository.master.SellerAccountRepository;
import com.hchbox.service.SellerAccountService; import com.hchbox.service.SellerAccountService;
import com.hchbox.service.TaoBaoOrderingService;
import com.hchbox.service.TaoBaoRdsPushService; import com.hchbox.service.TaoBaoRdsPushService;
import com.taobao.api.domain.ArticleSub;
import lombok.RequiredArgsConstructor; import lombok.RequiredArgsConstructor;
import lombok.extern.slf4j.Slf4j; import lombok.extern.slf4j.Slf4j;
import org.aspectj.lang.annotation.After;
import org.springframework.scheduling.annotation.Scheduled; import org.springframework.scheduling.annotation.Scheduled;
import org.springframework.stereotype.Component; import org.springframework.stereotype.Component;
import org.springframework.transaction.annotation.Transactional; import org.springframework.transaction.annotation.Transactional;
import java.util.Date; import java.util.Date;
import java.util.List; import java.util.List;
import java.util.Optional;
/** /**
* @author Enzo * @author Enzo
@ -29,19 +24,16 @@ import java.util.Optional;
@RequiredArgsConstructor @RequiredArgsConstructor
public class AccountTask { public class AccountTask {
private final SellerAccountRepository sellerAccountRepository; private final SellerAccountRepository sellerAccountRepository;
private final SellerAccountService sellerAccountService; private final SellerAccountService sellerAccountService;
private final TaoBaoRdsPushService taoBaoRdsPushService; private final TaoBaoRdsPushService taoBaoRdsPushService;
/** /**
* *
*/ */
@Scheduled(cron = " 0 1 0 * * ?") @Scheduled(cron = " 0 1 0 * * ?")
// @Scheduled(cron = "0 0/1 * * * *")
@Transactional(rollbackFor = Exception.class) @Transactional(rollbackFor = Exception.class)
public void deleteAccountAfterExpirationTime() { public void deleteAccountAfterExpirationTime() {
List<SellerAccount> sellerAccounts = List<SellerAccount> sellerAccounts =

Loading…
Cancel
Save