Commit d7678b15 authored by lcl's avatar lcl

u

parent 8e8fb36d
......@@ -29,24 +29,46 @@
where ctu.user_id = #{dto.userId} and ctu.status = #{dto.status}
<if test="dto.companyName != null and dto.companyName != '' "> and ct.company_name like concat('%',#{dto.companyName},'%')</if>
<if test="dto.isOn != null "> and ct.is_on = #{dto.isOn}</if>
<if test="dto.provinceIds != null and dto.provinceIds.size > 0 ">
and ct.province_id in
<if test="dto.provinceIds != null ">
and (ct.province_id in
<foreach collection="dto.provinceIds" item="item" open="(" separator="," close=")">
#{item}
</foreach>
<if test="dto.cityIds != null ">
or ct.city_id in
<foreach collection="dto.cityIds" item="item" open="(" separator="," close=")">
#{item}
</foreach>
</if>
<if test="dto.districtIds != null">
or ct.district_id in
<foreach collection="dto.districtIds" item="item" open="(" separator="," close=")">
#{item}
</foreach>
</if>
)
</if>
<if test="dto.cityIds != null and dto.cityIds.size > 0 ">
and ct.city_id in
<foreach collection="dto.cityIds" item="item" open="(" separator="," close=")">
#{item}
</foreach>
<if test="dto.provinceIds == null and dto.cityIds != null ">
and (ct.city_id in
<foreach collection="dto.cityIds" item="item" open="(" separator="," close=")">
#{item}
</foreach>
<if test="dto.districtIds != null">
or ct.district_id in
<foreach collection="dto.districtIds" item="item" open="(" separator="," close=")">
#{item}
</foreach>
</if>
)
</if>
<if test="dto.districtIds != null and dto.districtIds.size > 0 ">
<if test="dto.provinceIds == null and dto.cityIds == null and dto.districtIds != null">
and ct.district_id in
<foreach collection="dto.districtIds" item="item" open="(" separator="," close=")">
#{item}
</foreach>
</if>
<if test="dto.companyNatures != null and dto.companyNatures.size > 0 ">
and ct.company_nature in
<foreach collection="dto.companyNatures" item="item" open="(" separator="," close=")">
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment