|
|
@ -892,27 +892,27 @@ |
|
|
|
vs.OPPOSITION_COUNT |
|
|
|
FROM issue i |
|
|
|
LEFT JOIN issue_vote_statistical vs ON vs.ISSUE_ID = i.ID AND vs.DEL_FLAG = '0' |
|
|
|
WHERE DEL_FLAG = '0' |
|
|
|
WHERE i.DEL_FLAG = '0' |
|
|
|
<if test='null != startTime and startTime != "" '> |
|
|
|
AND DATE_FORMAT(CREATED_TIME,'%Y%m%d') >= #{startTime} |
|
|
|
AND DATE_FORMAT(i.CREATED_TIME,'%Y%m%d') >= #{startTime} |
|
|
|
</if> |
|
|
|
<if test='null != endTime and endTime != "" '> |
|
|
|
AND DATE_FORMAT(CREATED_TIME,'%Y%m%d') <![CDATA[ <= ]]> #{endTime} |
|
|
|
AND DATE_FORMAT(i.CREATED_TIME,'%Y%m%d') <![CDATA[ <= ]]> #{endTime} |
|
|
|
</if> |
|
|
|
<if test='null != issueStatus and issueStatus != "" '> |
|
|
|
AND ISSUE_STATUS = #{issueStatus} |
|
|
|
AND i.ISSUE_STATUS = #{issueStatus} |
|
|
|
</if> |
|
|
|
<if test='null != issueTitle and issueTitle != "" '> |
|
|
|
AND ISSUE_TITLE LIKE CONCAT('%',#{issueTitle},'%') |
|
|
|
AND i.ISSUE_TITLE LIKE CONCAT('%',#{issueTitle},'%') |
|
|
|
</if> |
|
|
|
<choose> |
|
|
|
<when test='orgType == "agency"'> |
|
|
|
AND ORG_ID_PATH LIKE CONCAT('%',#{orgId},'%') |
|
|
|
AND i.ORG_ID_PATH LIKE CONCAT('%',#{orgId},'%') |
|
|
|
</when> |
|
|
|
<otherwise> |
|
|
|
AND GRID_ID = #{orgId} |
|
|
|
AND i.GRID_ID = #{orgId} |
|
|
|
</otherwise> |
|
|
|
</choose> |
|
|
|
ORDER BY CREATED_TIME DESC |
|
|
|
ORDER BY i.CREATED_TIME DESC |
|
|
|
</select> |
|
|
|
</mapper> |