| 
															
																@ -66,6 +66,7 @@ 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; 
															 | 
														
													
												
													
														
															| 
															 | 
															
																import org.springframework.beans.factory.annotation.Value; 
															 | 
															
															 | 
															
																import org.springframework.beans.factory.annotation.Value; 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																import org.springframework.data.redis.core.StringRedisTemplate; 
															 | 
														
													
												
													
														
															| 
															 | 
															
																import org.springframework.jdbc.core.BeanPropertyRowMapper; 
															 | 
															
															 | 
															
																import org.springframework.jdbc.core.BeanPropertyRowMapper; 
															 | 
														
													
												
													
														
															| 
															 | 
															
																import org.springframework.jdbc.core.JdbcTemplate; 
															 | 
															
															 | 
															
																import org.springframework.jdbc.core.JdbcTemplate; 
															 | 
														
													
												
													
														
															| 
															 | 
															
																import org.springframework.stereotype.Service; 
															 | 
															
															 | 
															
																import org.springframework.stereotype.Service; 
															 | 
														
													
												
											
												
													
														
															 | 
															
																@ -77,6 +78,7 @@ import java.io.InputStream; 
															 | 
														
													
												
													
														
															| 
															 | 
															
																import java.io.OutputStream; 
															 | 
															
															 | 
															
																import java.io.OutputStream; 
															 | 
														
													
												
													
														
															| 
															 | 
															
																import java.lang.Boolean; 
															 | 
															
															 | 
															
																import java.lang.Boolean; 
															 | 
														
													
												
													
														
															| 
															 | 
															
																import java.util.*; 
															 | 
															
															 | 
															
																import java.util.*; 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																import java.util.concurrent.TimeUnit; 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																/** 
															 | 
															
															 | 
															
																/** 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 * Created by Trick on 2019/5/17 
															 | 
															
															 | 
															
																 * Created by Trick on 2019/5/17 
															 | 
														
													
												
											
												
													
														
															 | 
															
																@ -147,6 +149,8 @@ public class PrescriptionService extends BaseJpaService<WlyyPrescriptionDO, Pres 
															 | 
														
													
												
													
														
															| 
															 | 
															
																    private PrescriptionLogService prescriptionLogService; 
															 | 
															
															 | 
															
																    private PrescriptionLogService prescriptionLogService; 
															 | 
														
													
												
													
														
															| 
															 | 
															
																    @Autowired 
															 | 
															
															 | 
															
																    @Autowired 
															 | 
														
													
												
													
														
															| 
															 | 
															
																    private WlyyInspectionDao wlyyInspectionDao; 
															 | 
															
															 | 
															
																    private WlyyInspectionDao wlyyInspectionDao; 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																    @Autowired 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																    private StringRedisTemplate redisTemplate; 
															 | 
														
													
												
													
														
															| 
															 | 
															
																     
															 | 
															
															 | 
															
																     
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																    @Value("${demo.flag}") 
															 | 
															
															 | 
															
																    @Value("${demo.flag}") 
															 | 
														
													
												
											
												
													
														
															 | 
															
																@ -3147,6 +3151,7 @@ public class PrescriptionService extends BaseJpaService<WlyyPrescriptionDO, Pres 
															 | 
														
													
												
													
														
															| 
															 | 
															
																            //根据身份证计算年龄 
															 | 
															
															 | 
															
																            //根据身份证计算年龄 
															 | 
														
													
												
													
														
															| 
															 | 
															
																            for(Map<String,Object> outpatient :list){ 
															 | 
															
															 | 
															
																            for(Map<String,Object> outpatient :list){ 
															 | 
														
													
												
													
														
															| 
															 | 
															
																                String idcard = (String)outpatient.get("idcard"); 
															 | 
															
															 | 
															
																                String idcard = (String)outpatient.get("idcard"); 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																                String patient_id = (String)outpatient.get("patient_id"); 
															 | 
														
													
												
													
														
															| 
															 | 
															
																                outpatient.put("age",DateUtil.getAgeForIdcard(idcard)); 
															 | 
															
															 | 
															
																                outpatient.put("age",DateUtil.getAgeForIdcard(idcard)); 
															 | 
														
													
												
													
														
															| 
															 | 
															
																     
															 | 
															
															 | 
															
																     
															 | 
														
													
												
													
														
															| 
															 | 
															
																                String group_date = (String)outpatient.get("group_date"); 
															 | 
															
															 | 
															
																                String group_date = (String)outpatient.get("group_date"); 
															 | 
														
													
												
											
												
													
														
															 | 
															
																@ -3162,7 +3167,13 @@ public class PrescriptionService extends BaseJpaService<WlyyPrescriptionDO, Pres 
															 | 
														
													
												
													
														
															| 
															 | 
															
																                //全科医生来源 
															 | 
															
															 | 
															
																                //全科医生来源 
															 | 
														
													
												
													
														
															| 
															 | 
															
																                outpatient.put("general_doctor_info","");//全科医生名字 
															 | 
															
															 | 
															
																                outpatient.put("general_doctor_info","");//全科医生名字 
															 | 
														
													
												
													
														
															| 
															 | 
															
																                outpatient.put("general_doctor_hospital","");//全科医生社区 
															 | 
															
															 | 
															
																                outpatient.put("general_doctor_hospital","");//全科医生社区 
															 | 
														
													
												
													
														
															| 
															 | 
															
																                outpatient.put("alert_tag",0);//是否已提醒 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																                String isAlert = redisTemplate.opsForValue().get("patient_alert_"+patient_id); 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																                if(StringUtils.isBlank(isAlert)){ 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																                    outpatient.put("alert_tag",0);//已提醒 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																                }else{ 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																                    outpatient.put("alert_tag",1);//未提醒 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																                } 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																                 
															 | 
														
													
												
													
														
															| 
															 | 
															
																                outpatient.put("online_tag",0);//在线状态 
															 | 
															
															 | 
															
																                outpatient.put("online_tag",0);//在线状态 
															 | 
														
													
												
													
														
															| 
															 | 
															
																            } 
															 | 
															
															 | 
															
																            } 
															 | 
														
													
												
													
														
															| 
															 | 
															
																        } 
															 | 
															
															 | 
															
																        } 
															 |