| 
															
																@ -32,6 +32,7 @@ import javax.transaction.Transactional; 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																import org.apache.commons.lang.StringUtils; 
															 | 
															
															 | 
															
																import org.apache.commons.lang.StringUtils; 
															 | 
														
													
												
													
														
															| 
															 | 
															
																import org.springframework.beans.factory.annotation.Autowired; 
															 | 
															
															 | 
															
																import org.springframework.beans.factory.annotation.Autowired; 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																import org.springframework.beans.factory.annotation.Value; 
															 | 
														
													
												
													
														
															| 
															 | 
															
																import org.springframework.data.redis.core.StringRedisTemplate; 
															 | 
															
															 | 
															
																import org.springframework.data.redis.core.StringRedisTemplate; 
															 | 
														
													
												
													
														
															| 
															 | 
															
																import org.springframework.data.redis.core.ValueOperations; 
															 | 
															
															 | 
															
																import org.springframework.data.redis.core.ValueOperations; 
															 | 
														
													
												
													
														
															| 
															 | 
															
																import org.springframework.jdbc.core.JdbcTemplate; 
															 | 
															
															 | 
															
																import org.springframework.jdbc.core.JdbcTemplate; 
															 | 
														
													
												
											
												
													
														
															 | 
															
																@ -56,7 +57,12 @@ public class BaseBannerDoctorService 
															 | 
														
													
												
													
														
															| 
															 | 
															
																    private WlyyHospitalSysDictDao wlyyHospitalSysDictDao; 
															 | 
															
															 | 
															
																    private WlyyHospitalSysDictDao wlyyHospitalSysDictDao; 
															 | 
														
													
												
													
														
															| 
															 | 
															
																    @Autowired 
															 | 
															
															 | 
															
																    @Autowired 
															 | 
														
													
												
													
														
															| 
															 | 
															
																    private StringRedisTemplate redisTemplate; 
															 | 
															
															 | 
															
																    private StringRedisTemplate redisTemplate; 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																    @Value("${wechat.id}") 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																    private String wxId; 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																    @Value("${wechat.flag}") 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																    private boolean flag; 
															 | 
														
													
												
													
														
															| 
															 | 
															
																    @Transactional 
															 | 
															
															 | 
															
																    @Transactional 
															 | 
														
													
												
													
														
															| 
															 | 
															
																    public ObjEnvelop bannerGive(String patientId, List<String> list, String content, String doctor, String doctorName, Integer type, String key, String value) 
															 | 
															
															 | 
															
																    public ObjEnvelop bannerGive(String patientId, List<String> list, String content, String doctor, String doctorName, Integer type, String key, String value) 
															 | 
														
													
												
													
														
															| 
															 | 
															
																            throws IOException 
															 | 
															
															 | 
															
																            throws IOException 
															 | 
														
													
												
											
												
													
														
															 | 
															
																@ -386,7 +392,16 @@ public class BaseBannerDoctorService 
															 | 
														
													
												
													
														
															| 
															 | 
															
																        Date date = new Date(); 
															 | 
															
															 | 
															
																        Date date = new Date(); 
															 | 
														
													
												
													
														
															| 
															 | 
															
																        SimpleDateFormat format = new SimpleDateFormat("yyyy-MM-dd"); 
															 | 
															
															 | 
															
																        SimpleDateFormat format = new SimpleDateFormat("yyyy-MM-dd"); 
															 | 
														
													
												
													
														
															| 
															 | 
															
																        String strDate = format.format(date); 
															 | 
															
															 | 
															
																        String strDate = format.format(date); 
															 | 
														
													
												
													
														
															| 
															 | 
															
																        sql.append(" and t.create_time > '" + strDate + " 00:00:00' and t.create_time<'" + strDate + " 23:59:59'"); 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																        if("xm_ykyy_wx".equals(wxId)){ 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																            if (flag){ 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																                sql.append(" and t.create_time > '" + strDate + " 00:00:00' and t.create_time<'" + strDate + " 23:59:59'"); 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																            }else { 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																                sql.append(" and t.create_time > to_date('" + strDate + " 00:00:00', 'yyyy-mm-dd hh24:mi:ss') and t.create_time< to_date('" + strDate + " 23:59:59','yyyy-mm-dd hh24:mi:ss')"); 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																            } 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																        }else{ 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																            sql.append(" and t.create_time > '" + strDate + " 00:00:00' and t.create_time<'" + strDate + " 23:59:59'"); 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																        } 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																        List<Map<String, Object>> list = this.hibenateUtils.createSQLQuery(sql.toString()); 
															 | 
															
															 | 
															
																        List<Map<String, Object>> list = this.hibenateUtils.createSQLQuery(sql.toString()); 
															 | 
														
													
												
													
														
															| 
															 | 
															
																        WlyyHospitalSysDictDO wlyyHospitalSysDictDO = this.wlyyHospitalSysDictDao.findById("leave_message_times"); 
															 | 
															
															 | 
															
																        WlyyHospitalSysDictDO wlyyHospitalSysDictDO = this.wlyyHospitalSysDictDao.findById("leave_message_times"); 
															 | 
														
													
												
													
														
															| 
															 | 
															
																        long countTimes = 5L; 
															 | 
															
															 | 
															
																        long countTimes = 5L; 
															 |