Commit ef15bb16 by zhengxj

finish 修正技工管理列表查询sql on 20191113 by zhengxj

git-svn-id: svn://192.168.3.233/frms/code/car-service/trunk/car-service@24802 aeb6102e-e053-11e5-9fec-f9ebc45caf4b
1 parent 618ae036
......@@ -1015,8 +1015,17 @@
and u.id = #{id,jdbcType=INTEGER}
</if>
<if test="keyWord != null and keyWord!=''">
and( u.name like "%"#{keyWord}"%" or su.name like "%"#{keyWord}"%" or u.phone_number like "%"#{keyWord}"%" )
</if>
<choose>
<when test="mechanicId != null ">
and( u.name like "%"#{keyWord}"%" or su.name like "%"#{keyWord}"%"
or u.phone_number like "%"#{keyWord}"%" OR u.id like #{mechanicId} )
</when>
<otherwise>
and( u.name like "%"#{keyWord}"%" or su.name like "%"#{keyWord}"%"
or u.phone_number like "%"#{keyWord}"%" )
</otherwise>
</choose>
</if>
<if test="mechanicId != null ">
OR u.id like #{mechanicId}
......@@ -1107,18 +1116,21 @@
WHERE u.user_type = 3
</otherwise>
</choose>
<if test="id != null">
and u.id = #{id,jdbcType=INTEGER}
</if>
<if test="keyWord != null and keyWord!=''">
and( u.name like "%"#{keyWord}"%" or su.name like "%"#{keyWord}"%" or u.phone_number like "%"#{keyWord}"%" )
</if>
<if test="mechanicId != null ">
OR u.id like #{mechanicId}
</if>
<if test="keyWord != null and keyWord!=''">
<choose>
<when test="mechanicId != null ">
and( u.name like "%"#{keyWord}"%" or su.name like "%"#{keyWord}"%"
or u.phone_number like "%"#{keyWord}"%" OR u.id like #{mechanicId} )
</when>
<otherwise>
and( u.name like "%"#{keyWord}"%" or su.name like "%"#{keyWord}"%"
or u.phone_number like "%"#{keyWord}"%" )
</otherwise>
</choose>
</if>
<if test="serviceType != null and serviceType!=''">
and sm.service_type = #{serviceType,jdbcType=VARCHAR}
</if>
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!