Bladeren bron

每日推送接口BUG修改

huangwenjie 7 jaren geleden
bovenliggende
commit
14d94705b5

+ 1 - 1
patient-co/patient-co-wlyy-job/pom.xml

@ -474,7 +474,7 @@
                    <target>1.8</target>
                    <compilerArguments>
                        <verbose/>
                        <bootclasspath>${java.home}/lib/rt.jar;${java.home}/lib/jce.jar</bootclasspath>
                        <bootclasspath>${java.home}/lib/rt.jar:${java.home}/lib/jce.jar</bootclasspath>
                    </compilerArguments>
                </configuration>
                <version>3.1</version>

+ 1 - 1
patient-co/patient-co-wlyy/pom.xml

@ -507,7 +507,7 @@
                    <target>1.8</target>
                    <compilerArguments>
                        <verbose/>
                        <bootclasspath>${java.home}/lib/rt.jar;${java.home}/lib/jce.jar</bootclasspath>
                        <bootclasspath>${java.home}/lib/rt.jar:${java.home}/lib/jce.jar</bootclasspath>
                    </compilerArguments>
                </configuration>
                <version>3.1</version>

+ 22 - 13
patient-co/patient-co-wlyy/src/main/java/com/yihu/wlyy/service/jimeiJkEdu/JMJkEduArticleService.java

@ -722,21 +722,30 @@ public class JMJkEduArticleService extends BaseService {
        if (!StringUtils.isEmpty(labelHealth) || !StringUtils.isEmpty(labelDisease)) {
            tableSql += " left join wlyy_sign_patient_label_info l on w.patient=l.patient ";
            whereSql += " and l.status=1 ";
            whereSql += " and ( ";
        }
        if (!StringUtils.isEmpty(labelHealth)) {
            whereSql += " (l.label_type = 2 AND l.label in (" + labelHealth + ")) ";
        }
        if (!StringUtils.isEmpty(labelDisease)) {
            if (!whereSql.endsWith(" and ( ")) {
                whereSql += " or (l.label_type = 3 AND l.label in (" + labelDisease + ")) ";
            } else {
                whereSql += " l.label_type = 1 AND l.label in (" + labelDisease + ")) ";
    
            if (!StringUtils.isEmpty(labelHealth) && !StringUtils.isEmpty(labelDisease)) {
                whereSql += " and ( (l.label_type = 2 AND l.label in (" + labelHealth + ") ) or (l.label_type = 3 AND l.label in (" + labelDisease + ") ))";
            }else {
                if(!StringUtils.isEmpty(labelHealth)){
                    whereSql += " and (l.label_type = 2 AND l.label in (" + labelHealth + "))";
                }
                
                if(!StringUtils.isEmpty(labelDisease)){
                    whereSql += " and (l.label_type = 3 AND l.label in (" + labelDisease + "))";
                }
            }
        }
        if (!StringUtils.isEmpty(labelHealth) || !StringUtils.isEmpty(labelDisease)) {
            whereSql += ")";
        }
//        if (!StringUtils.isEmpty(labelDisease)) {
//            if (!whereSql.endsWith(" and ( ")) {
//                whereSql += " or (l.label_type = 3 AND l.label in (" + labelDisease + "))) ";
//            } else {
//                whereSql += " l.label_type = 3 AND l.label in (" + labelDisease + ")) ";
//            }
//        }
//        if (!StringUtils.isEmpty(labelHealth) || !StringUtils.isEmpty(labelDisease)) {
//            whereSql += ")";
//        }
        
        tableSql += " left join wlyy_patient p on p.code=w.patient AND p.openid IS NOT NULL and p.openid <>''";
        if (!StringUtils.isEmpty(labelSex)) {

+ 2 - 2
patient-co/patient-co-wlyy/src/main/resources/application-devtest.yml

@ -101,11 +101,11 @@ pushMes:
  redis_prescription_title: redisMessage
es:
  index:
    HealthEduArticlePatient: health_edu_article_patient_test5
    HealthEduArticlePatient: health_edu_article_patient_test3
    FollowUp: wlyy_followup
    Statistics: wlyy_quota_test
  type:
    HealthEduArticlePatient: health_edu_article_patient_test5
    HealthEduArticlePatient: health_edu_article_patient_test3
    FollowUpContent: wlyy_followup_content
    Statistics: wlyy_quota_test
  host:  http://172.19.103.68:9200

+ 1 - 1
pom.xml

@ -610,7 +610,7 @@
                        <target>1.8</target>
                        <compilerArguments>
                            <verbose/>
                            <bootclasspath>${java.home}/lib/rt.jar;${java.home}/lib/jce.jar</bootclasspath>
                            <bootclasspath>${java.home}/lib/rt.jar:${java.home}/lib/jce.jar</bootclasspath>
                        </compilerArguments>
                    </configuration>
                    <version>3.1</version>