|
@@ -8,6 +8,7 @@ import com.steerinfo.ems.emsgmpcjh.service.IEmsGmPcJhService;
|
|
|
import com.steerinfo.ems.emsscqklg.service.IEmsScqkLgService;
|
|
|
import com.steerinfo.ems.emsscqklg.service.ILgRealService;
|
|
|
import com.steerinfo.ems.emswaterrealtime.service.IEmsWaterRealtimeService;
|
|
|
+import com.steerinfo.ems.foldthevalues.service.IFoldTheValuesService;
|
|
|
import com.steerinfo.ems.ifemsmesactitem.service.IIfEmsMesActitemService;
|
|
|
import com.steerinfo.ems.ifmesemsproductorder.service.IIfMesEmsProductorderService;
|
|
|
import com.steerinfo.ems.ifmesemsswapfile.service.IIfMesEmsSwapfileService;
|
|
@@ -44,11 +45,10 @@ import org.springframework.scheduling.config.ScheduledTaskRegistrar;
|
|
|
import org.springframework.scheduling.support.CronTrigger;
|
|
|
import org.springframework.stereotype.Service;
|
|
|
|
|
|
+import javax.script.ScriptException;
|
|
|
import java.text.ParseException;
|
|
|
-import java.util.Date;
|
|
|
-import java.util.List;
|
|
|
-import java.util.Map;
|
|
|
-import java.util.Properties;
|
|
|
+import java.text.SimpleDateFormat;
|
|
|
+import java.util.*;
|
|
|
import java.util.concurrent.ConcurrentHashMap;
|
|
|
import java.util.concurrent.ScheduledFuture;
|
|
|
|
|
@@ -122,6 +122,8 @@ public class SpringCronTask implements SchedulingConfigurer{
|
|
|
IEmsScqkLgService emsScqkLgService;
|
|
|
@Autowired
|
|
|
ILgRealService lgRealService;
|
|
|
+ @Autowired
|
|
|
+ IFoldTheValuesService foldTheValuesService;
|
|
|
/**
|
|
|
* SchedulingConfigurer接口的方法实现,加载后自动运行
|
|
|
*/
|
|
@@ -305,7 +307,21 @@ public class SpringCronTask implements SchedulingConfigurer{
|
|
|
dzMaterialSfService.dataGeneration();
|
|
|
emsScqkLgService.dateGenerate();
|
|
|
logger.info("定时任务"+taskId+"执行时长:" + (new Date().getTime() - start)/1000 + "秒");
|
|
|
- } //else if (taskId.equalsIgnoreCase("124")) {
|
|
|
+ }
|
|
|
+ else if(taskId.equalsIgnoreCase("124")){
|
|
|
+ long start = new Date().getTime();
|
|
|
+ try {
|
|
|
+ foldTheValuesService.getDate();
|
|
|
+ Calendar c = Calendar.getInstance();
|
|
|
+ if(c.get(Calendar.DATE) == 1){
|
|
|
+ foldTheValuesService.getMonthDate();
|
|
|
+ }
|
|
|
+ } catch (Exception e) {
|
|
|
+ e.printStackTrace();
|
|
|
+ }
|
|
|
+ logger.info("定时任务"+taskId+"执行时长:" + (new Date().getTime() - start)/1000 + "秒");
|
|
|
+ }
|
|
|
+ //else if (taskId.equalsIgnoreCase("124")) {
|
|
|
// // 每10秒获取一次炼钢实时数据传入mosaic
|
|
|
// long start = System.currentTimeMillis();
|
|
|
// try {
|