38 lines
1.3 KiB
Java
38 lines
1.3 KiB
Java
package com.ruoyi;
|
|
|
|
import com.ruoyi.jd.task.QueueUploadTask;
|
|
import org.slf4j.Logger;
|
|
import org.slf4j.LoggerFactory;
|
|
import org.springframework.beans.factory.annotation.Autowired;
|
|
import org.springframework.boot.ApplicationArguments;
|
|
import org.springframework.boot.ApplicationRunner;
|
|
import org.springframework.stereotype.Component;
|
|
|
|
/**
|
|
* @Description TODO
|
|
* @Author maj
|
|
* @Date 2021/5/11 13:22
|
|
*/
|
|
@Component
|
|
public class AfterServiceStarted implements ApplicationRunner {
|
|
|
|
protected Logger logger = LoggerFactory.getLogger(this.getClass());
|
|
@Autowired
|
|
QueueUploadTask queueUploadTask;
|
|
@Override
|
|
public void run(ApplicationArguments args) throws Exception {
|
|
// if(!DateUtils.getDayCheck(CodeConstants.IMPORT_EXECUTE)){
|
|
// logger.info("--------------每月15号后不启动导入文件---------------");
|
|
// return ;
|
|
// }
|
|
// String ip = GetHostIP.getInnetIp();
|
|
// if (ip.equals(CodeConstants.IP_25) || ip.equals(CodeConstants.IP_26)
|
|
// || ip.equals(CodeConstants.IP_28) || ip.equals(CodeConstants.IP_29)
|
|
// || ip.equals(CodeConstants.IP_30) ) {
|
|
// logger.info("--------------是否启动导入文件---------------:{}", ip);
|
|
// queueUploadTask.queueUploadFile();
|
|
// }
|
|
}
|
|
|
|
}
|