Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
J
jfV5portal
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
管理员
jfV5portal
Commits
cf40a06d
Commit
cf40a06d
authored
Sep 17, 2018
by
罗绍泽
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
主题查询bug修复
parent
07d9f753
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
14 additions
and
3 deletions
+14
-3
topicDAO.xml
src_jwapp/com/jw/app/business/forum/topic/topicDAO.xml
+14
-3
No files found.
src_jwapp/com/jw/app/business/forum/topic/topicDAO.xml
View file @
cf40a06d
...
@@ -22,6 +22,9 @@
...
@@ -22,6 +22,9 @@
<sql
id=
"where_topic_reply"
>
<sql
id=
"where_topic_reply"
>
<where>
<where>
<trim
prefixOverrides=
"AND |OR"
>
<trim
prefixOverrides=
"AND |OR"
>
<if
test=
"CONTENT_LIKE != null and CONTENT_LIKE != ''"
>
and ftr.CONTENT LIKE #{CONTENT_LIKE}
</if>
<if
test=
"UUID != null and UUID != ''"
>
<if
test=
"UUID != null and UUID != ''"
>
and ftr.UUID = #{UUID}
and ftr.UUID = #{UUID}
</if>
</if>
...
@@ -44,13 +47,17 @@
...
@@ -44,13 +47,17 @@
uu1.USER_NAME AS POST_USER_NAME,
uu1.USER_NAME AS POST_USER_NAME,
uu2.USER_NAME AS CREATE_USER_NAME,
uu2.USER_NAME AS CREATE_USER_NAME,
uu3.USER_NAME AS UPDATE_USER_NAME,
uu3.USER_NAME AS UPDATE_USER_NAME,
IFNULL(
vtr
.reply_count,0) AS REPLY_COUNT
IFNULL(
reply
.reply_count,0) AS REPLY_COUNT
FROM FORUM_TOPIC ft
FROM FORUM_TOPIC ft
LEFT JOIN forum_classify fc ON ft.classify_id = fc.uuid
LEFT JOIN forum_classify fc ON ft.classify_id = fc.uuid
LEFT JOIN uicm_user uu1 ON ft.post_user = uu1.USER_ID
LEFT JOIN uicm_user uu1 ON ft.post_user = uu1.USER_ID
LEFT JOIN uicm_user uu2 ON ft.CREATE_ID = uu2.USER_ID
LEFT JOIN uicm_user uu2 ON ft.CREATE_ID = uu2.USER_ID
LEFT JOIN uicm_user uu3 ON ft.UPDATE_ID = uu3.USER_ID
LEFT JOIN uicm_user uu3 ON ft.UPDATE_ID = uu3.USER_ID
LEFT JOIN view_forum_topic_reply vtr ON vtr.topic_id = ft.uuid
LEFT JOIN (
SELECT topic_id,COUNT(*) as reply_count
FROM forum_topic_reply
GROUP BY topic_id
) reply ON reply.topic_id = ft.uuid
]]>
]]>
<include
refid=
"where_topic"
/>
<include
refid=
"where_topic"
/>
ORDER BY ft.stick_flag DESC,ft.post_time DESC
ORDER BY ft.stick_flag DESC,ft.post_time DESC
...
@@ -64,7 +71,11 @@
...
@@ -64,7 +71,11 @@
LEFT JOIN uicm_user uu1 ON ft.post_user = uu1.USER_ID
LEFT JOIN uicm_user uu1 ON ft.post_user = uu1.USER_ID
LEFT JOIN uicm_user uu2 ON ft.CREATE_ID = uu2.USER_ID
LEFT JOIN uicm_user uu2 ON ft.CREATE_ID = uu2.USER_ID
LEFT JOIN uicm_user uu3 ON ft.UPDATE_ID = uu3.USER_ID
LEFT JOIN uicm_user uu3 ON ft.UPDATE_ID = uu3.USER_ID
LEFT JOIN view_forum_topic_reply vtr ON vtr.topic_id = ft.uuid
LEFT JOIN (
SELECT topic_id,COUNT(*) as reply_count
FROM forum_topic_reply
GROUP BY topic_id
) reply ON reply.topic_id = ft.uuid
]]>
]]>
<include
refid=
"where_topic"
/>
<include
refid=
"where_topic"
/>
</select>
</select>
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment