Selaa lähdekoodia

Merge branch 'dev' of http://192.168.1.220:10080/Amoy2/wlyy2.0 into dev

# Conflicts:
#	common/common-entity/sql记录
yeshijie 3 vuotta sitten
vanhempi
commit
2f766dff1d

+ 5 - 5
svr/svr-cloud-care/src/main/java/com/yihu/jw/care/service/patient/CarePatientService.java

@ -474,14 +474,13 @@ public class CarePatientService extends BaseJpaService<BasePatientDO, BasePatien
        }
        if("3".equals(type)||StringUtil.isBlank(type)){
            filter = "";
            String sqltmp = "SELECT GROUP_CONCAT(dict_code) orgCodes from wlyy_hospital_sys_dict WHERE dict_name = 'jkzl_helper' ";
            String sqltmp = "SELECT GROUP_CONCAT(dict_code) orgCodes from wlyy_hospital_sys_dict WHERE dict_name = 'jkzl_org' ";
            List<Map<String,Object>> listtmp =  jdbcTemplate.queryForList(sqltmp);
            if(listtmp.size()>0){
                String orgCodes = String.valueOf(listtmp.get(0).get("orgCodes"));
                orgCodes = orgCodes.replaceAll(",","','");
                filter = " and id not in ('"+orgCodes+"')";
                filter = " and h.org_code not in ('"+orgCodes+"')";
            }
            List<Map<String,Object>> list = findHelper(name,limit,filter);
            re.put("helper",list);
@ -601,9 +600,10 @@ public class CarePatientService extends BaseJpaService<BasePatientDO, BasePatien
     * @return
     */
    public List<Map<String,Object>> findHelper(String name,String limit,String fileter){
        String sql = "SELECT id,name,photo,sex,IFNULL(on_line,0) online from base_doctor WHERE doctor_level = 2 and del = '1' ";
        String sql = "SELECT a.id,a.name,a.photo,a.sex,IFNULL(a.on_line,0) online from base_doctor a,base_doctor_hospital h" +
                "  WHERE a.id=h.doctor_code and a.doctor_level = 2 and a.del = '1' and h.del = '1' ";
        if(!StringUtil.isBlank(name)){
            sql+= " and name like '%"+name+"%' ";
            sql+= " a.and name like '%"+name+"%' ";
        }
        sql += fileter;
        sql += " ORDER BY online desc";