Commit 3d9e9cd5 by 陶光胜

投诉建议查询加上企业id

parent d0c18887
......@@ -275,38 +275,35 @@
select
<include refid="Base_Column_List" />
from tab_problem where enterprise_id = #{enterpriseId}
<where>
<if test="null != problemIds and problemIds.length &gt; 0">
and problem_id in
<foreach close=")" collection="problemIds" index="index" item="item" open="(" separator=",">
#{item}
</foreach>
</if>
<if test="null != storeIdList and storeIdList.size &gt; 0">
and store_id in
<foreach close=")" collection="storeIdList" index="index" item="item" open="(" separator=",">
#{item}
</foreach>
<if test="null != problemIds and problemIds.length &gt; 0">
and problem_id in
<foreach close=")" collection="problemIds" index="index" item="item" open="(" separator=",">
#{item}
</foreach>
</if>
<if test="null != storeIdList and storeIdList.size &gt; 0">
and store_id in
<foreach close=")" collection="storeIdList" index="index" item="item" open="(" separator=",">
#{item}
</foreach>
</if>
<if test="search != null and search != '' ">
and (
member_name like concat('%', #{search}, '%')
or member_phone like concat('%', #{search}, '%')
or store_name like concat('%', #{search}, '%')
or problem_content like concat('%', #{search}, '%')
)
</if>
<if test="problemStatus != null ">
and problem_status = #{problemStatus}
</if>
<if test="startTime != null and startTime != '' ">
and create_time &gt;= #{startTime}
</if>
<if test="endTime != null and endTime != '' ">
and create_time &lt;= #{endTime}
</if>
<if test="search != null and search != '' ">
and (
member_name like concat('%', #{search}, '%')
or member_phone like concat('%', #{search}, '%')
or store_name like concat('%', #{search}, '%')
or problem_content like concat('%', #{search}, '%')
)
</if>
<if test="problemStatus != null ">
and problem_status = #{problemStatus}
</if>
<if test="startTime != null and startTime != '' ">
and create_time &gt;= #{startTime}
</if>
<if test="endTime != null and endTime != '' ">
and create_time &lt;= #{endTime}
</if>
</where>
order by create_time desc
</select>
<select id="countProblem" resultType="int">
......
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