|
@ -2129,13 +2129,13 @@ public class WlyyDoorServiceOrderService extends BaseJpaService<WlyyDoorServiceO
|
|
|
String sql = "select ds.doctor,d.name, d.job_title_name as jobName, 1 as sortFlag " +
|
|
|
" from wlyy_door_doctor_status ds " +
|
|
|
" JOIN (select b.* from base_doctor b,base_doctor_hospital dh where b.id=dh.doctor_code and dh.del = 1 and dh.org_code='" + hospital + "') d on ds.doctor = d.id " +
|
|
|
" where ds.status in (1,2,3,4)" +
|
|
|
" LEFT JOIN base_doctor_role dr ON dr.doctor_code = d.id where ds.status in (1,2,3,4) AND dr.role_code != 'nurse' GROUP BY doctor " +
|
|
|
" limit " + start + "," + end ;
|
|
|
|
|
|
String countSql = "select count(ds.id) " +
|
|
|
"from wlyy_door_doctor_status ds " +
|
|
|
" JOIN (select b.* from base_doctor b,base_doctor_hospital dh where b.id=dh.doctor_code and dh.del = 1 and dh.org_code= '" + hospital + "') d on ds.doctor = d.id " +
|
|
|
"where ds.status in (1,2,3,4)";
|
|
|
" LEFT JOIN base_doctor_role dr ON dr.doctor_code = d.id where ds.status in (1,2,3,4) AND dr.role_code != 'nurse' GROUP BY doctor ";
|
|
|
List<Map<String,Object>> doctorList = new ArrayList<>();
|
|
|
try {
|
|
|
doctorList = jdbcTemplate.queryForList(sql);
|