| package com.zy.nc.task; | 
|   | 
| import com.zy.asrs.task.core.ReturnT; | 
| import com.zy.nc.task.handler.BaseDataHandler; | 
| import lombok.extern.slf4j.Slf4j; | 
| import org.springframework.beans.factory.annotation.Autowired; | 
| import org.springframework.scheduling.annotation.Scheduled; | 
| import org.springframework.stereotype.Component; | 
|   | 
| @Slf4j | 
| @Component | 
| public class BaseDataTask { | 
|   | 
|     @Autowired | 
|     private BaseDataHandler baseDataHandler; | 
|   | 
|     @Scheduled(cron = "0/3 * * * * ? ") | 
|     public void execute1() { | 
| //        ReturnT<String> returnT = baseDataHandler.start1(); | 
| //        if (!returnT.isSuccess()) { | 
| //            log.error(returnT.getMsg()); | 
| //        } | 
|     } | 
|   | 
|     /** | 
|      * 人员数据同步 | 
|      */ | 
|     @Scheduled(cron = "0/3 * * * * ? ") | 
|     public void start8() { | 
|         ReturnT<String> returnT = baseDataHandler.start8(); | 
|         if (!returnT.isSuccess()) { | 
|             log.error(returnT.getMsg()); | 
|         } | 
|     } | 
|   | 
|   | 
|   | 
|     /** | 
|      * 物料分类数据同步 | 
|      */ | 
|     @Scheduled(cron = "0/3 * * * * ? ") | 
|     public void start9() { | 
|         ReturnT<String> returnT = baseDataHandler.start9(); | 
|         if (!returnT.isSuccess()) { | 
|             log.error(returnT.getMsg()); | 
|         } | 
|     } | 
|   | 
|     /** | 
|      * 物料基础数据同步 | 
|      */ | 
|     @Scheduled(cron = "0/3 * * * * ? ") | 
|     public void execute13() { | 
|         ReturnT<String> returnT = baseDataHandler.start13(); | 
|         if (!returnT.isSuccess()) { | 
|             log.error(returnT.getMsg()); | 
|         } | 
|     } | 
|   | 
|   | 
|     /** | 
|      * 仓库基础数据同步 | 
|      */ | 
|     @Scheduled(cron = "0/3 * * * * ? ") | 
|     public void execute6() { | 
|         ReturnT<String> returnT = baseDataHandler.start6(); | 
|         if (!returnT.isSuccess()) { | 
|             log.error(returnT.getMsg()); | 
|         } | 
|     } | 
| } |