package com.ruoyi.other.task;
|
|
import com.ruoyi.other.service.TExchangeCodePackageService;
|
import com.ruoyi.other.service.TStationInfoService;
|
import org.springframework.scheduling.annotation.Scheduled;
|
import org.springframework.stereotype.Component;
|
|
import javax.annotation.Resource;
|
|
@Component
|
public class ExchangeCodeExpireTask {
|
|
@Resource
|
private TExchangeCodePackageService exchangeCodePackageService;
|
|
@Resource
|
private TStationInfoService tStationInfoService;
|
|
@Scheduled(cron = "0 */5 * * * ?")
|
public void refreshExpiredPackageCodes() {
|
exchangeCodePackageService.refreshExpiredPackageCodes();
|
}
|
|
/**
|
* 每天11点执行科士达的数据同步
|
*/
|
@Scheduled(cron = "0 0 23 * * ?")
|
public void syncKsolarDataTask() {
|
tStationInfoService.syncKsolarDataTask();
|
}
|
}
|