Browse Source

修改BUG

dev
liuchuang 6 years ago
parent
commit
f5d9d273a3
  1. 26
      esua-epdc/epdc-module/epdc-events/epdc-events-server/src/main/resources/mapper/item/ItemDao.xml

26
esua-epdc/epdc-module/epdc-events/epdc-events-server/src/main/resources/mapper/item/ItemDao.xml

@ -50,6 +50,8 @@
item.ITEM_STATE
WHEN 0 THEN
'处理中'
WHEN 5 THEN
'已关闭'
WHEN 10 THEN
'已结案' ELSE ''
END AS stateName
@ -75,30 +77,30 @@
ON t1.EVENT_ID = t2.ID
AND t2.DEL_FLAG = '0'
WHERE t1.DEL_FLAG = '0'
AND t1.GRID_ID = #{deptId}
AND t1.GRID_ID = #{formDto.deptId}
AND t1.ITEM_STATE IN
<foreach collection="states" item="state" index="no" open="("
separator="," close=")">
#{state}
</foreach>
<if test="someMonthsAgo != null">
<![CDATA[ AND DATE_FORMAT(t1.CREATED_TIME,'%Y-%m-%d %H:%i:%s') >= ]]> #{someMonthsAgo}
<if test="formDto.someMonthsAgo != null">
<![CDATA[ AND DATE_FORMAT(t1.CREATED_TIME,'%Y-%m-%d %H:%i:%s') >= ]]> #{formDto.someMonthsAgo}
</if>
<if test="timestamp != null">
<![CDATA[ AND DATE_FORMAT(t1.CREATED_TIME,'%Y-%m-%d %H:%i:%s') <= ]]> #{timestamp}
<if test="formDto.timestamp != null">
<![CDATA[ AND DATE_FORMAT(t1.CREATED_TIME,'%Y-%m-%d %H:%i:%s') <= ]]> #{formDto.timestamp}
</if>
<if test='searchContent != null and searchContent != ""'>
AND t1.ITEM_CONTENT LIKE CONCAT('%',#{searchContent},'%')
<if test='formDto.searchContent != null and formDto.searchContent != ""'>
AND t1.ITEM_CONTENT LIKE CONCAT('%',#{formDto.searchContent},'%')
</if>
<if test='categoryId != null and categoryId != ""'>
AND t1.ISSUE_CATEGORY_ID = #{categoryId}
<if test='formDto.categoryId != null and formDto.categoryId != ""'>
AND t1.ISSUE_CATEGORY_ID = #{formDto.categoryId}
</if>
<if test='userId != null and userId != ""'>
AND t1.USER_ID = #{userId}
<if test='formDto.userId != null and formDto.userId != ""'>
AND t1.USER_ID = #{formDto.userId}
</if>
ORDER BY
t1.CREATED_TIME DESC
LIMIT #{pageIndex},#{pageSize}
LIMIT #{formDto.pageIndex},#{formDto.pageSize}
) temp
)
ORDER BY

Loading…
Cancel
Save