| 
															
																@ -1,6 +1,8 @@ 
															 | 
														
													
												
													
														
															| 
															 | 
															
																package com.yihu.jw.event; 
															 | 
															
															 | 
															
																package com.yihu.jw.event; 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																import com.yihu.jw.job.QuartzHelper; 
															 | 
															
															 | 
															
																import com.yihu.jw.job.QuartzHelper; 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																import com.yihu.jw.job.wlw.InventoryWarningJob; 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																import com.yihu.jw.util.SystemConf; 
															 | 
														
													
												
													
														
															| 
															 | 
															
																import org.slf4j.Logger; 
															 | 
															
															 | 
															
																import org.slf4j.Logger; 
															 | 
														
													
												
													
														
															| 
															 | 
															
																import org.slf4j.LoggerFactory; 
															 | 
															
															 | 
															
																import org.slf4j.LoggerFactory; 
															 | 
														
													
												
													
														
															| 
															 | 
															
																import org.springframework.beans.factory.annotation.Autowired; 
															 | 
															
															 | 
															
																import org.springframework.beans.factory.annotation.Autowired; 
															 | 
														
													
												
											
												
													
														
															 | 
															
																@ -8,6 +10,8 @@ import org.springframework.context.ApplicationListener; 
															 | 
														
													
												
													
														
															| 
															 | 
															
																import org.springframework.context.event.ContextRefreshedEvent; 
															 | 
															
															 | 
															
																import org.springframework.context.event.ContextRefreshedEvent; 
															 | 
														
													
												
													
														
															| 
															 | 
															
																import org.springframework.stereotype.Service; 
															 | 
															
															 | 
															
																import org.springframework.stereotype.Service; 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																import java.util.HashMap; 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																/** 
															 | 
															
															 | 
															
																/** 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 * Created by zdm on 2017/3/10. 
															 | 
															
															 | 
															
																 * Created by zdm on 2017/3/10. 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 */ 
															 | 
															
															 | 
															
																 */ 
															 | 
														
													
												
											
												
													
														
															 | 
															
																@ -21,41 +25,18 @@ public class ApplicationEvent implements ApplicationListener<ContextRefreshedEve 
															 | 
														
													
												
													
														
															| 
															 | 
															
																    @Override 
															 | 
															
															 | 
															
																    @Override 
															 | 
														
													
												
													
														
															| 
															 | 
															
																    public void onApplicationEvent(ContextRefreshedEvent ContextRefreshedEvent) { 
															 | 
															
															 | 
															
																    public void onApplicationEvent(ContextRefreshedEvent ContextRefreshedEvent) { 
															 | 
														
													
												
													
														
															| 
															 | 
															
																        try { 
															 | 
															
															 | 
															
																        try { 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																//=================中山医院发布启动====================================================== 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																//            //互联网医院处方状态更新job 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																//            if (!quartzHelper.isExistJob("prescriptionStatus_update_job")) { 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																//                String trigger = SystemConf.getInstance().getSystemProperties().getProperty("prescriptionStatus_update_job"); 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																//                quartzHelper.addJob(PrescriptionStatusUpdateJob.class, trigger, "prescriptionStatus_update_job", new HashMap<String, Object>()); 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																//                logger.info("prescriptionStatus_update_job  job success"); 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																//            } else { 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																//                logger.info("prescriptionStatus_update_job  job exist"); 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																//            } 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																// 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																//            //门诊过期 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																//            if (!quartzHelper.isExistJob("prescription_overdue_job")) { 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																//                String trigger = SystemConf.getInstance().getSystemProperties().getProperty("prescription_overdue_job"); 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																//                quartzHelper.addJob(PrescriptionOverdueJob.class, trigger, "prescription_overdue_job", new HashMap<String, Object>()); 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																//                logger.info("prescription_overdue_job  job success"); 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																//            } else { 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																//                logger.info("prescription_overdue_job  job exist"); 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																//            } 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																// 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																// 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																//            //互联网医院 监管平台上报 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																//            if (!quartzHelper.isExistJob("data_upload_job")) { 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																//                String trigger = SystemConf.getInstance().getSystemProperties().getProperty("data_upload_job"); 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																//                quartzHelper.addJob(DataUploadJob.class, trigger, "data_upload_job", new HashMap<String, Object>()); 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																//                logger.info("data_upload_job  job success"); 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																//            } else { 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																//                logger.info("data_upload_job  job exist"); 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																//            } 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																//=================中山医院发布启动====================================================== 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																            //设备库存预警提醒 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																            if (!quartzHelper.isExistJob("device_inventory_warning_job")) { 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																                String trigger = SystemConf.getInstance().getSystemProperties().getProperty("device_inventory_warning_job"); 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																                quartzHelper.addJob(InventoryWarningJob.class, trigger, "device_inventory_warning_job", new HashMap<String, Object>()); 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																                logger.info("device_inventory_warning_job  job success"); 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																            } else { 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																                logger.info("device_inventory_warning_job  job exist"); 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																            } 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																        } catch (Exception e) { 
															 | 
															
															 | 
															
																        } catch (Exception e) { 
															 | 
														
													
												
													
														
															| 
															 | 
															
																            logger.info("followup_plan_remind job start failed"); 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																            logger.info(" job start failed"); 
															 | 
														
													
												
													
														
															| 
															 | 
															
																        } 
															 | 
															
															 | 
															
																        } 
															 | 
														
													
												
													
														
															| 
															 | 
															
																    } 
															 | 
															
															 | 
															
																    } 
															 | 
														
													
												
													
														
															| 
															 | 
															
																} 
															 | 
															
															 | 
															
																} 
															 |