|
|
@@ -294,8 +294,7 @@ public class SyncOrgElementsBaseInfoServiceImpl implements SyncOrgElementsBaseIn
|
|
|
SqlRowList orgs = baseDao.queryForRowSet("select row_number() over (order by or_id) rn, case when nvl" +
|
|
|
"(or_landrayid,' ')=' ' then to_char(or_id) else or_landrayid end or_id,or_code,or_name ," +
|
|
|
"or_parentname,or_headmancode,or_headmanname,or_path, (select case when nvl(em_landrayemid,' ')=' ' " +
|
|
|
- "then to_char(em_id) else em_landrayemid end from hrorg ho left join employee on ho" +
|
|
|
- ".or_headmancode=em_code where ho.or_id=hr.or_subof) as superLeader,or_statuscode,or_landraysubid," +
|
|
|
+ "then to_char(em_id) else em_landrayemid end from employee where or_leadmancode_user=em_code) as superLeader,or_statuscode,or_landraysubid," +
|
|
|
"to_char(or_subof) or_subof,case when nvl(em_landrayemid,' ')=' ' then to_char(em_id) else " +
|
|
|
"em_landrayemid end emid from hrorg hr left join employee on hr.or_headmancode=em_code where " +
|
|
|
"nvl(or_subof,0)>0 order by rn");
|