|
@@ -34,16 +34,24 @@
|
|
|
<select id="getEnvironmentLeader" parameterType="EnvironmentLeaderVO" resultType="EnvironmentLeaderBO">
|
|
|
SELECT
|
|
|
a.name as nickName,
|
|
|
- u.user_id as userId
|
|
|
+ u.user_id as userId,
|
|
|
+ a.phone phone,
|
|
|
+ d.dept_name deptName,
|
|
|
+ a.environment_job environmentJob,
|
|
|
+ b.dict_label environmentLabel
|
|
|
FROM
|
|
|
centerdata_t_environment_person a
|
|
|
LEFT JOIN ${database_system}.sys_dept d ON a.dept_id = d.dept_id
|
|
|
LEFT JOIN ${database_system}.sys_user u ON a.user_id = u.user_id
|
|
|
+ left join ${database_system}.sys_dict_data b on a.environment_job = b.dict_value
|
|
|
WHERE
|
|
|
1 = 1
|
|
|
<if test="environmentJob != null and environmentJob != ''">
|
|
|
and a.environment_job=#{environmentJob}
|
|
|
</if>
|
|
|
+ <if test="name != null and name != ''">
|
|
|
+ and a.name like concat('%', #{name}, '%')
|
|
|
+ </if>
|
|
|
<choose>
|
|
|
<when test="deptId != null and deptId != ''">and FIND_IN_SET( #{deptId}, CONCAT(d.ancestors,',',d.dept_id) )</when>
|
|
|
<otherwise>${params.dataScope}</otherwise>
|