LAPTOP-KB9HII50\70708 2 місяців тому
батько
коміт
74ebf7c720

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

@ -8687,7 +8687,7 @@ public class StatisticsEsService {
        String followupSql = "SELECT COUNT(f.id) planNum,COUNT(if(f.`status`=1,1,null)) finishNum from wlyy_followup f" +
                " where f.followup_date >='"+startDate+"' and f.followup_date <='"+endDate+"' ";
        if(StringUtils.isNotBlank(deptCode)){
            followupSql += "SELECT COUNT(f.id) planNum,COUNT(if(f.`status`=1,1,null)) finishNum from wlyy_followup f,base_doctor_hospital h " +
            followupSql = "SELECT COUNT(f.id) planNum,COUNT(if(f.`status`=1,1,null)) finishNum from wlyy_followup f,base_doctor_hospital h " +
                    " where f.doctor_code=h.doctor_code and h.del=1 and h.dept_code='"+deptCode+"' " +
                    " and f.followup_date >='"+startDate+"' and f.followup_date <='"+endDate+"' ";
        }
@ -8720,10 +8720,10 @@ public class StatisticsEsService {
                turnSqlT += " and dept = '"+deptCode+"' ";
                turnPersonSqlH += " and dept = '"+deptCode+"' ";
                turnPersonSqlT += " and dept = '"+deptCode+"' ";
                followupSqlH += "SELECT COUNT(f.id) planNum from wlyy_followup f,base_doctor_hospital h " +
                followupSqlH = "SELECT COUNT(f.id) planNum from wlyy_followup f,base_doctor_hospital h " +
                        " where f.doctor_code=h.doctor_code and h.del=1 and h.dept_code='"+deptCode+"' " +
                        " and f.followup_date >='"+period[0]+"' and f.followup_date <='"+period[1]+"' ";
                followupSqlT += "SELECT COUNT(f.id) planNum from wlyy_followup f,base_doctor_hospital h " +
                followupSqlT = "SELECT COUNT(f.id) planNum from wlyy_followup f,base_doctor_hospital h " +
                        " where f.doctor_code=h.doctor_code and h.del=1 and h.dept_code='"+deptCode+"' " +
                        " and f.followup_date >='"+periodYear[0]+"' and f.followup_date <='"+periodYear[1]+"' ";
            }

+ 14 - 2
svr/svr-visit-behind/src/main/java/com/yihu/jw/hospital/module/followup/service/FollowUpService.java

@ -105,7 +105,13 @@ public class FollowUpService {
                "LEFT JOIN base_doctor_hospital h2 on pl.plan_doctor=h2.doctor_code and h2.del=1 " +
                "WHERE 1=1 ";
        if(StringUtils.isNotBlank(businessType)){
            filter += " and pl.disease='"+businessType+"' ";
            if(businessType.contains(",")){
                businessType = businessType.replace(",","','");
                businessType = " in ('"+businessType+"') ";
            }else {
                businessType = " = '"+businessType+"' ";
            }
            filter += " and pl.disease "+businessType+" ";
        }
        if(StringUtils.isNotBlank(businessSource)){
@ -175,7 +181,13 @@ public class FollowUpService {
                "LEFT JOIN base_doctor_hospital h2 on pl.plan_doctor=h2.doctor_code and h2.del=1 " +
                "WHERE 1=1 ";
        if(StringUtils.isNotBlank(businessType)){
            filter += " and pl.disease='"+businessType+"' ";
            if(businessType.contains(",")){
                businessType = businessType.replace(",","','");
                businessType = " in ('"+businessType+"') ";
            }else {
                businessType = " = '"+businessType+"' ";
            }
            filter += " and pl.disease "+businessType+" ";
        }
        if(StringUtils.isNotBlank(businessSource)){