|
@ -43,8 +43,9 @@ public class PatientSosContactsJob implements Job {
|
|
|
logger.info("PATIENT_SOS_CONTACTS_JOB start");
|
|
|
|
|
|
String sql = " select pd.device_sn,pd.category_code,wd.sim,sc.* from wlyy_patient_device pd inner join wlyy_devices wd " +
|
|
|
" on pd.device_sn = wd.device_code and pd.del=0 and wd.sim is not null and pd.category_code in('7','4') " +
|
|
|
"INNER JOIN base_patient_sos_contacts sc on sc.patient = pd.user and sc.del=1 and sc.success_flag=0 group by wd.sim";
|
|
|
" on pd.device_sn = wd.device_code and pd.del=0 " +
|
|
|
"INNER JOIN base_patient_sos_contacts sc on sc.patient = pd.user and sc.del=1 " +
|
|
|
"where sc.success_flag=0 group by wd.device_code ";
|
|
|
List<Map<String,Object>> sims = jdbcTemplate.queryForList(sql);
|
|
|
List<PatientSosContactsDO> modify = new ArrayList<>();
|
|
|
for(Map<String,Object> tmp:sims){//添加白名单,添加设备联系人
|