|
@ -42,7 +42,7 @@ public class BaseDoctorService extends BaseJpaService<BaseDoctorDO, BaseDoctorDa
|
|
|
* @param page
|
|
|
* @param pageSize
|
|
|
*/
|
|
|
public Envelop queryList(String city, String hospital, String status, String name, int page, int pageSize){
|
|
|
public Envelop queryList(String city, String hospital, String status, String name, String type, int page, int pageSize){
|
|
|
Map<String,Object> params = new HashedMap();
|
|
|
String sqlTotal ="SELECT " +
|
|
|
" COUNT(1) AS \"total\" " +
|
|
@ -70,6 +70,11 @@ public class BaseDoctorService extends BaseJpaService<BaseDoctorDO, BaseDoctorDa
|
|
|
sqlTotal += " AND (a.name like:name or b.dept_name like:name)";
|
|
|
params.put("name",name);
|
|
|
}
|
|
|
if (StringUtils.isNotBlank(type)){
|
|
|
type = "%"+type+"%";
|
|
|
sqlTotal += " AND a.outpatient_type like:type";
|
|
|
params.put("type",type);
|
|
|
}
|
|
|
sqlTotal += " AND e.dept_type_code =:typeCode";
|
|
|
params.put("typeCode",6);
|
|
|
Long count = 0L;
|
|
@ -105,6 +110,9 @@ public class BaseDoctorService extends BaseJpaService<BaseDoctorDO, BaseDoctorDa
|
|
|
if (StringUtils.isNotBlank(name)){
|
|
|
sql += " AND (a.name like:name or b.dept_name like:name)";
|
|
|
}
|
|
|
if (StringUtils.isNotBlank(type)){
|
|
|
sql += " AND a.outpatient_type like:type";
|
|
|
}
|
|
|
sql += " AND e.dept_type_code =:typeCode";
|
|
|
|
|
|
List<Map<String,Object>> list = hibenateUtils.createSQLQuery(sql,params,page,pageSize);
|