<?xml version="1.0" encoding="UTF-8" ?> <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
<mapper namespace="com.ruoyi.collaborativeApproval.mapper.SealApplicationManagementMapper">
|
|
|
<select id="listPage" resultType="com.ruoyi.collaborativeApproval.dto.SealApplicationManagementDTO">
|
SELECT
|
sam.*,
|
su.user_name AS create_user_name,
|
|
GROUP_CONCAT(DISTINCT d.dept_name ORDER BY d.dept_id SEPARATOR ',') AS department,
|
|
su1.nick_name AS approveUserName
|
|
FROM seal_application_management sam
|
|
LEFT JOIN sys_user su
|
ON sam.create_user = su.user_id
|
|
LEFT JOIN sys_user su1
|
ON sam.approve_user_id = su1.user_id
|
|
LEFT JOIN sys_user_dept sud
|
ON su.user_id = sud.user_id
|
|
LEFT JOIN sys_dept d
|
ON sud.dept_id = d.dept_id
|
<where>
|
<if test="ew.applicationNum != null and ew.applicationNum != ''">
|
and sam.application_num like concat('%',#{ew.applicationNum},'%')
|
</if>
|
<if test="ew.title != null and ew.title != ''">
|
and sam.title like concat('%',#{ew.title},'%')
|
</if>
|
<if test="ew.status != null">
|
and sam.status = #{ew.status}
|
</if>
|
</where>
|
GROUP BY sam.id
|
</select>
|
</mapper>
|