瀏覽代碼

三院检查对接

wangzhinan 10 月之前
父節點
當前提交
88cc5830fe

+ 4 - 4
business/es-service/src/main/java/com/yihu/jw/es/service/StatisticsEsService.java

@ -8004,10 +8004,10 @@ public class StatisticsEsService {
        //指标12,14,16
        //接诊量
        String indexSql = "SELECT COUNT(ct.id)  FROM wlyy_consult_outpatient_info ct " +
                "WHERE  ct.type IN(1,9,12,15,16,17) and ct.visite_status=1 AND ct.create_time <'"+qvo.getEndDate()+" 23:59:59' AND ct.create_time >='"+qvo.getStartDate()+"' ";
                "WHERE  ct.type IN(1,9,12,15,16,17) and ct.visite_status=1 AND ct.create_time <'"+qvo.getEndDate()+" 23:59:59' AND ct.create_time >='"+qvo.getStartDate()+" 00:00:00'  ";
        String index5Sql = "SELECT COUNT(ct.id)  FROM wlyy_consult_outpatient_info ct " +
                "WHERE  ct.type IN(1,9,12,15,16,17) AND ct.create_time <'"+qvo.getEndDate()+" 23:59:59' AND ct.create_time >='"+qvo.getStartDate()+"' ";
                "WHERE  ct.type IN(1,9,12,15,16,17) AND ct.create_time <'"+qvo.getEndDate()+" 23:59:59' AND ct.create_time >='"+qvo.getStartDate()+" 00:00:00' ";
        String score = jdbcTemplate.queryForObject(scoreSql, String.class);
        resultMap.put("score", score);//赋值评分
@ -8404,7 +8404,7 @@ public class StatisticsEsService {
                "FROM\n" +
                "	wlyy_prescription p\n" +
                "	INNER JOIN wlyy_outpatient o ON p.outpatient_id = o.id \n" +
                "	INNER JOIN base_doctor_hospital a ON p.doctor=a.doctor_code\n" +
                "	INNER JOIN base_doctor_hospital a ON p.doctor=a.doctor_code and a.del=1 \n" +
                "WHERE\n" +
                "	1 = 1 \n" +
                "	AND p.STATUS >= 30\n";
@ -8425,7 +8425,7 @@ public class StatisticsEsService {
                "FROM\n" +
                "	wlyy_outpatient o\n" +
                "	INNER JOIN base_business_order_pay bop ON o.id = bop.relation_code \n" +
                "	INNER JOIN base_doctor_hospital a ON o.doctor=a.doctor_code\n" +
                "	INNER JOIN base_doctor_hospital a ON o.doctor=a.doctor_code and a.del=1 \n" +
                "WHERE\n" +
                "	o.pay_status = 1 \n" +
                "	AND o.`status` IN ( 1, 2, 3 )\n";

+ 9 - 9
business/im-service/src/main/java/com/yihu/jw/im/service/ImService.java

@ -4310,23 +4310,23 @@ public class ImService {
        //咨询类型
        if (!StringUtils.isEmpty(type)) {
            if (type.equalsIgnoreCase("9")) {
                sql += " AND op.type =1 and op.outpatient_type = 1";
                sql += " AND op.type =1 and op.outpatient_type = 1";//图文问诊
            } else if (type.equalsIgnoreCase("16")) {
                sql += " AND op.type =2 and op.outpatient_type = 1";
                sql += " AND op.type =2 and op.outpatient_type = 1";//视频问诊
            } else if (type.equalsIgnoreCase("1")) {
                sql += " AND op.type =1 and (op.outpatient_type = 3 or op.outpatient_type=5) ";
                sql += " AND op.type =1 and op.outpatient_type = 3 ";//专家咨询和护理咨询
            } else if (type.equalsIgnoreCase("15")) {
                sql += " AND op.type =3 and op.outpatient_type = 3";
                sql += " AND op.type =3 and op.outpatient_type = 3";//
            } else if (type.equalsIgnoreCase("17")) {
                sql += " AND op.type =2 and op.outpatient_type = 3";
                sql += " AND op.type =2 and op.outpatient_type = 3";//视频咨询
            } else if (type.equalsIgnoreCase("12")) {
                sql += " AND op.outpatient_type = 2";
                sql += " AND op.outpatient_type = 2";//协同
            } else if (type.equalsIgnoreCase("28")) {
                sql += " AND op.outpatient_type = 4";
                sql += " AND op.outpatient_type = 4"; //康复咨询
            } else if (type.equalsIgnoreCase("29")) {
                sql += " AND op.outpatient_type = 1 and  oh.id is not null ";
                sql += " AND op.outpatient_type = 1 and  oh.id is not null "; //住院申请咨询
            } else if (type.equalsIgnoreCase("30")) {
                sql += " AND op.outpatient_type = 5";
                sql += " AND op.outpatient_type = 5";//护理咨询
            }  else {
                sql += " AND op.type in (1,2,3) ";
            }