IntelligentRecognition/ah-jjsp-service/.svn/pristine/fb/fb698b0459b95dd22e2e0f716d8...

71 lines
1.8 KiB
Plaintext

package com.sercurityControl.proteam.config;
import com.sercurityControl.proteam.dutyTask.service.TaskService;
import com.sercurityControl.proteam.dutyTask.service.WorkTeamSchedule;
import com.sercurityControl.proteam.service.DeviceMachineService;
import com.sercurityControl.proteam.service.impl.LogsServiceImpl;
import org.springframework.context.annotation.Configuration;
import org.springframework.scheduling.annotation.EnableScheduling;
import org.springframework.scheduling.annotation.Scheduled;
import javax.annotation.PostConstruct;
import javax.annotation.Resource;
/**
* 站班会进行管理 自动分配定时任务
* @author HeiZi
*/
@Configuration
@EnableScheduling
public class ClassMettingScheduTask {
@Resource
public WorkTeamSchedule schedule;
@Resource
private TaskService taskService;
@Resource
private DeviceMachineService dcmService;
@Resource
private LogsServiceImpl logsService;
/**
* 全部球机定时更状态
*/
@Scheduled(cron = "0 0/30 * * * ?")
private void updateAllState(){
taskService.updateAllState();
}
/**
* 站班会自动分配
*/
@Scheduled(cron = "0 39 * * * ?")
private void classMettingZdFp(){
schedule.classMettingZdFp();
}
/**
* 站班会预警
*/
@Scheduled(cron = "0 15,45 * * * ?")
@PostConstruct
private void getAllClassMettingWarn(){
taskService.getAllClassMettingWarn();
}
/**
* 数据定时入库
*/
@Scheduled(cron = "0 0 7,12,17 * * ?")
private void refreshRedisUtil(){
dcmService.refreshRedisUtilSchedule();
}
/**
* 推送日志服务接口
*/
@Scheduled(cron = "0 30 6 * * ? ")
private void LogFileUploadTask(){
logsService.LoginFileUpload();
}
}