处理福利带名字查询失败

This commit is contained in:
钱涛 2022-06-28 10:35:30 +08:00
parent 12fe1405ba
commit 43175f6e40
1 changed files with 62 additions and 0 deletions

View File

@ -366,6 +366,67 @@
<sql id="condition">
<if test="param.keyword != null and param.keyword != ''">
AND
(
userName like CONCAT('%',#{param.userName},'%')
OR jobNum = #{param.keyword}
)
</if>
<if test="param.userName != null and param.userName != ''">
AND userName like CONCAT('%',#{param.userName},'%')
</if>
<if test="param.jobNum != null and param.jobNum != ''">
AND jobNum = #{param.jobNum}
</if>
<if test="param.departmentIds != null and param.departmentIds.size()>0">
AND departmentId IN
<foreach collection="param.departmentIds" open="(" item="departmentId" separator="," close=")">
#{departmentId}
</foreach>
</if>
<if test="param.statuses != null and param.statuses.size()>0">
AND userStatus IN
<foreach collection="param.statuses" open="(" item="userStatus" separator="," close=")">
#{userStatus}
</foreach>
</if>
<if test="param.positions != null and param.positions.size()>0">
AND position IN
<foreach collection="param.positions" open="(" item="position" separator="," close=")">
#{position}
</foreach>
</if>
<if test="param.hiredateStart != null">
AND hiredate &gt; #{param.hiredateStart}
</if>
<if test="param.hiredateEnd != null">
AND hiredate &lt; #{param.hiredateEnd}
</if>
<if test="param.dimissionDateStart != null">
AND dimissionDate &gt; #{param.dimissionDateStart}
</if>
<if test="param.dimissionDateEnd != null">
AND dimissionDate &lt; #{param.dimissionDateEnd}
</if>
<if test="param.siSchemeId != null and param.siSchemeId != 0">
AND siSchemeId = #{param.siSchemeId}
</if>
<if test="param.fundSchemeId != null and param.fundSchemeId != 0">
AND fundSchemeId = #{param.fundSchemeId}
</if>
<if test="param.otherSchemeId != null and param.otherSchemeId != 0">
AND otherSchemeId = #{param.otherSchemeId}
</if>
<if test="param.employeeIds != null and param.employeeIds.size() > 0">
AND employeeId IN
<foreach collection="param.employeeIds" open="(" separator="," item="item" close=")">
#{item}
</foreach>
</if>
</sql>
<sql id="condition" databaseId="sqlserver">
<if test="param.keyword != null and param.keyword != ''">
AND
(
@ -426,6 +487,7 @@
</if>
</sql>
<sql id="condition" databaseId="oracle">
<if test="param.keyword != null and param.keyword != ''">
AND