|
@ -488,7 +488,7 @@ public class SignPatientLabelInfoService extends BaseService {
|
|
|
List<PatientVO> plist = new ArrayList<>();
|
|
|
if(sign.get("patient") != null){
|
|
|
String patientsql = "select a.*,b.deviceType as deviceType,c.disease as disease from wlyy_patient a" +
|
|
|
" left join (select user,sum(category_code) deviceType FROM wlyy_patient_device GROUP BY user) b on a.code = b.user" +
|
|
|
" left join (select user,group_concat(category_code) deviceType FROM wlyy_patient_device GROUP BY user) b on a.code = b.user" +
|
|
|
" left join (select patient,group_concat(label) disease from wlyy_sign_patient_label_info where label_type = 3 and status=1 " +
|
|
|
" and (label = 1 or label = 2) and patient = '"+sign.get("patient").toString()+"' GROUP BY patient) c on a.code = c.patient" +
|
|
|
" where a.status =1 and a.code = '"+sign.get("patient").toString()+"'";
|
|
@ -609,7 +609,7 @@ public class SignPatientLabelInfoService extends BaseService {
|
|
|
//预警状态
|
|
|
json.put("standardStatus",p.getStandardStatus());
|
|
|
//设备状态:0未绑定,1血糖仪,2血压仪,3血糖仪+血压仪
|
|
|
json.put("deviceType",p.getDeviceType());
|
|
|
json.put("deviceType",p.getDeviceType()==null?"":p.getDeviceType());
|
|
|
|
|
|
boolean epTime = false;
|
|
|
try {
|
|
@ -2422,7 +2422,7 @@ public class SignPatientLabelInfoService extends BaseService {
|
|
|
List<PatientVO> plist = new ArrayList<>();
|
|
|
if(sign.get("patient") != null){
|
|
|
String patientsql = "select a.*,b.deviceType as deviceType,c.disease as disease from wlyy_patient a" +
|
|
|
" left join (select user,sum(category_code) deviceType FROM wlyy_patient_device GROUP BY user) b on a.code = b.user" +
|
|
|
" left join (select user,group_concat(category_code) deviceType FROM wlyy_patient_device GROUP BY user) b on a.code = b.user" +
|
|
|
" left join (select patient,group_concat(label) disease from wlyy_sign_patient_label_info where label_type = 3 and status=1 " +
|
|
|
" and (label = 1 or label = 2) and patient = '"+sign.get("patient").toString()+"' GROUP BY patient) c on a.code = c.patient" +
|
|
|
" where a.status =1 and a.code = '"+sign.get("patient").toString()+"'";
|
|
@ -2566,7 +2566,7 @@ public class SignPatientLabelInfoService extends BaseService {
|
|
|
//预警状态
|
|
|
json.put("standardStatus", p.getStandardStatus());
|
|
|
//设备状态:0未绑定,1血糖仪,2血压仪,3血糖仪+血压仪
|
|
|
json.put("deviceType",p.getDeviceType());
|
|
|
json.put("deviceType",p.getDeviceType()==null?"":p.getDeviceType());
|
|
|
|
|
|
|
|
|
boolean epTime = false;
|
|
@ -2700,7 +2700,7 @@ public class SignPatientLabelInfoService extends BaseService {
|
|
|
List<PatientVO> plist = new ArrayList<>();
|
|
|
if(sign.get("patient") != null){
|
|
|
String patientsql = "select a.*,b.deviceType as deviceType,c.disease as disease from wlyy_patient a" +
|
|
|
" left join (select user,sum(category_code) deviceType FROM wlyy_patient_device GROUP BY user) b on a.code = b.user" +
|
|
|
" left join (select user,group_concat(category_code) deviceType FROM wlyy_patient_device GROUP BY user) b on a.code = b.user" +
|
|
|
" left join (select patient,group_concat(label) disease from wlyy_sign_patient_label_info where label_type = 3 and status=1 " +
|
|
|
" and (label = 1 or label = 2) and patient = '"+sign.get("patient").toString()+"' GROUP BY patient) c on a.code = c.patient" +
|
|
|
" where a.status =1 and a.code = '"+sign.get("patient").toString()+"'";
|
|
@ -2844,7 +2844,7 @@ public class SignPatientLabelInfoService extends BaseService {
|
|
|
//预警状态
|
|
|
json.put("standardStatus", p.getStandardStatus());
|
|
|
//设备状态:0未绑定,1血糖仪,2血压仪,3血糖仪+血压仪
|
|
|
json.put("deviceType",p.getDeviceType());
|
|
|
json.put("deviceType",p.getDeviceType()==null?"":p.getDeviceType());
|
|
|
|
|
|
boolean epTime = false;
|
|
|
try {
|
|
@ -3528,7 +3528,7 @@ public class SignPatientLabelInfoService extends BaseService {
|
|
|
List<PatientVO> plist = new ArrayList<>();
|
|
|
if(sign.get("patient") != null){
|
|
|
String patientsql = "select a.*,b.deviceType as deviceType,c.disease as disease from wlyy_patient a" +
|
|
|
" left join (select user,sum(category_code) deviceType FROM wlyy_patient_device GROUP BY user) b on a.code = b.user" +
|
|
|
" left join (select user,group_concat(category_code) deviceType FROM wlyy_patient_device GROUP BY user) b on a.code = b.user" +
|
|
|
" left join (select patient,group_concat(label) disease from wlyy_sign_patient_label_info where label_type = 3 and status=1 " +
|
|
|
" and (label = 1 or label = 2) and patient = '"+sign.get("patient").toString()+"' GROUP BY patient) c on a.code = c.patient" +
|
|
|
" where a.status =1 and a.code = '"+sign.get("patient").toString()+"'";
|
|
@ -3656,7 +3656,7 @@ public class SignPatientLabelInfoService extends BaseService {
|
|
|
//预警状态
|
|
|
json.put("standardStatus", p.getStandardStatus());
|
|
|
//设备状态:0未绑定,1血糖仪,2血压仪,3血糖仪+血压仪
|
|
|
json.put("deviceType",p.getDeviceType());
|
|
|
json.put("deviceType",p.getDeviceType()==null?"":p.getDeviceType());
|
|
|
|
|
|
boolean epTime = false;
|
|
|
try {
|
|
@ -3717,7 +3717,7 @@ public class SignPatientLabelInfoService extends BaseService {
|
|
|
List<PatientVO> plist = new ArrayList<>();
|
|
|
if(sign.get("patient") != null){
|
|
|
String patientsql = "select a.*,b.deviceType as deviceType,c.disease as disease from wlyy_patient a" +
|
|
|
" left join (select user,sum(category_code) deviceType FROM wlyy_patient_device GROUP BY user) b on a.code = b.user" +
|
|
|
" left join (select user,group_concat(category_code) deviceType FROM wlyy_patient_device GROUP BY user) b on a.code = b.user" +
|
|
|
" left join (select patient,group_concat(label) disease from wlyy_sign_patient_label_info where label_type = 3 and status=1 " +
|
|
|
" and (label = 1 or label = 2) and patient = '"+sign.get("patient").toString()+"' GROUP BY patient) c on a.code = c.patient" +
|
|
|
" where a.status =1 and a.code = '"+sign.get("patient").toString()+"'";
|
|
@ -3845,7 +3845,7 @@ public class SignPatientLabelInfoService extends BaseService {
|
|
|
//预警状态
|
|
|
json.put("standardStatus", p.getStandardStatus());
|
|
|
//设备状态:0未绑定,1血糖仪,2血压仪,3血糖仪+血压仪
|
|
|
json.put("deviceType",p.getDeviceType());
|
|
|
json.put("deviceType",p.getDeviceType()==null?"":p.getDeviceType());
|
|
|
|
|
|
boolean epTime = false;
|
|
|
try {
|
|
@ -4023,17 +4023,6 @@ public class SignPatientLabelInfoService extends BaseService {
|
|
|
sql = sql + " limit " + start + "," + pagesize;
|
|
|
signList = jdbcTemplate.queryForList(sql, args);
|
|
|
|
|
|
// //查询患者设备绑定情况
|
|
|
// String _pdsql = "select user,sum(category_code) deviceType FROM wlyy_patient_device GROUP BY user";
|
|
|
// List<Map<String,Object>> patientCodeDeviceTypes = jdbcTemplate.queryForList(_pdsql);
|
|
|
//
|
|
|
// if(!patientCodeDeviceTypes.isEmpty()){
|
|
|
// for (Map<String,Object> patientCodeDeviceType : patientCodeDeviceTypes) {
|
|
|
// String user = String.valueOf(patientCodeDeviceType.get("user"));
|
|
|
// String sum = String.valueOf(patientCodeDeviceType.get("deviceType"));
|
|
|
// patientDeviceTypeMap.put(user,sum);
|
|
|
// }
|
|
|
// }
|
|
|
|
|
|
if (signList != null && signList.size() > 0) {
|
|
|
for (Map<String, Object> sign : signList) {
|
|
@ -4046,8 +4035,8 @@ public class SignPatientLabelInfoService extends BaseService {
|
|
|
PatientVO p = new PatientVO();
|
|
|
List<PatientVO> plist = new ArrayList<>();
|
|
|
if(sign.get("patient") != null){
|
|
|
String patientsql = "select a.*,b.deviceType as deviceType,c.disease as disease from wlyy_patient a" +
|
|
|
" left join (select user,sum(category_code) deviceType FROM wlyy_patient_device GROUP BY user) b on a.code = b.user" +
|
|
|
String patientsql = "select a.*,b. as deviceType,c.disease as disease from wlyy_patient a" +
|
|
|
" left join (select user,group_concat(category_code) deviceType FROM wlyy_patient_device GROUP BY user) b on a.code = b.user" +
|
|
|
" left join (select patient,group_concat(label) disease from wlyy_sign_patient_label_info where label_type = 3 and status=1 " +
|
|
|
" and (label = 1 or label = 2) and patient = '"+sign.get("patient").toString()+"' GROUP BY patient) c on a.code = c.patient" +
|
|
|
" where a.status =1 and a.code = '"+sign.get("patient").toString()+"'";
|
|
@ -4174,7 +4163,7 @@ public class SignPatientLabelInfoService extends BaseService {
|
|
|
// deviceType = (String) patientDeviceTypeMap.get(p.getCode());
|
|
|
// }
|
|
|
//设备状态:0未绑定,1血糖仪,2血压仪,3血糖仪+血压仪
|
|
|
json.put("deviceType",p.getDeviceType());
|
|
|
json.put("deviceType",p.getDeviceType()==null?"":p.getDeviceType());
|
|
|
|
|
|
|
|
|
boolean epTime = false;
|
|
@ -4498,7 +4487,7 @@ public class SignPatientLabelInfoService extends BaseService {
|
|
|
List<PatientVO> plist = new ArrayList<>();
|
|
|
if(sign.get("patient") != null){
|
|
|
String patientsql = "select a.*,b.deviceType as deviceType,c.disease as disease from wlyy_patient a" +
|
|
|
" left join (select user,sum(category_code) deviceType FROM wlyy_patient_device GROUP BY user) b on a.code = b.user" +
|
|
|
" left join (select user,group_concat(category_code) deviceType FROM wlyy_patient_device GROUP BY user) b on a.code = b.user" +
|
|
|
" left join (select patient,group_concat(label) disease from wlyy_sign_patient_label_info where label_type = 3 and status=1 " +
|
|
|
" and (label = 1 or label = 2) and patient = '"+sign.get("patient").toString()+"' GROUP BY patient) c on a.code = c.patient" +
|
|
|
" where a.status =1 and a.code = '"+sign.get("patient").toString()+"'";
|
|
@ -4643,7 +4632,7 @@ public class SignPatientLabelInfoService extends BaseService {
|
|
|
//预警状态
|
|
|
json.put("standardStatus",p.getStandardStatus());
|
|
|
//设备状态:0未绑定,1血糖仪,2血压仪,3血糖仪+血压仪
|
|
|
json.put("deviceType",p.getDeviceType());
|
|
|
json.put("deviceType",p.getDeviceType()==null?"":p.getDeviceType());
|
|
|
|
|
|
boolean epTime = false;
|
|
|
try {
|
|
@ -4709,7 +4698,7 @@ public class SignPatientLabelInfoService extends BaseService {
|
|
|
List<PatientVO> plist = new ArrayList<>();
|
|
|
if(sign.get("patient") != null){
|
|
|
String patientsql = "select a.*,b.deviceType as deviceType,c.disease as disease from wlyy_patient a" +
|
|
|
" left join (select user,sum(category_code) deviceType FROM wlyy_patient_device GROUP BY user) b on a.code = b.user" +
|
|
|
" left join (select user,group_concat(category_code) deviceType FROM wlyy_patient_device GROUP BY user) b on a.code = b.user" +
|
|
|
" left join (select patient,group_concat(label) disease from wlyy_sign_patient_label_info where label_type = 3 and status=1 " +
|
|
|
" and (label = 1 or label = 2) and patient = '"+sign.get("patient").toString()+"' GROUP BY patient) c on a.code = c.patient" +
|
|
|
" where a.status =1 and a.code = '"+sign.get("patient").toString()+"'";
|
|
@ -4837,7 +4826,7 @@ public class SignPatientLabelInfoService extends BaseService {
|
|
|
//预警状态
|
|
|
json.put("standardStatus",p.getStandardStatus());
|
|
|
//设备状态:0未绑定,1血糖仪,2血压仪,3血糖仪+血压仪
|
|
|
json.put("deviceType",p.getDeviceType());
|
|
|
json.put("deviceType",p.getDeviceType()==null?"":p.getDeviceType());
|
|
|
|
|
|
boolean epTime = false;
|
|
|
try {
|