Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Sign in
Toggle navigation
T
tanpu-community
Project
Project
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
Packages
Packages
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
探普后端
tanpu-community
Commits
a20c600c
Commit
a20c600c
authored
Sep 24, 2021
by
王亚雷
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
游客权限
parent
c59d6916
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
4 additions
and
10 deletions
+4
-10
CommentController.java
...ava/com/tanpu/community/controller/CommentController.java
+1
-5
HomePageController.java
...va/com/tanpu/community/controller/HomePageController.java
+3
-5
No files found.
community-service/src/main/java/com/tanpu/community/controller/CommentController.java
View file @
a20c600c
...
...
@@ -11,7 +11,6 @@ import com.tanpu.community.api.beans.req.comment.QueryCommentReq;
import
com.tanpu.community.api.beans.req.comment.ReportCommentReq
;
import
com.tanpu.community.api.beans.req.page.Page
;
import
com.tanpu.community.manager.CommentManager
;
import
com.tanpu.community.util.HttpServletHelper
;
import
com.tanpu.community.util.PageUtils
;
import
io.swagger.annotations.ApiOperation
;
import
lombok.extern.slf4j.Slf4j
;
...
...
@@ -33,9 +32,6 @@ public class CommentController {
@Resource
private
UserHolder
userHolder
;
@Resource
HttpServletHelper
httpServletHelper
;
@ApiOperation
(
"发表评论"
)
@AuthLogin
@PostMapping
(
value
=
"/publishComment"
)
...
...
@@ -49,7 +45,7 @@ public class CommentController {
@PostMapping
(
value
=
"/queryComment"
)
@ResponseBody
public
CommonResp
<
Page
<
CommentQo
>>
queryComment
(
@Validated
@RequestBody
QueryCommentReq
req
)
{
String
selfUserId
=
httpServletHelper
.
getCurren
tUserId
();
String
selfUserId
=
userHolder
.
ge
tUserId
();
List
<
CommentQo
>
result
=
commentManager
.
queryComments
(
req
.
getThemeId
(),
selfUserId
);
return
CommonResp
.
success
(
PageUtils
.
page
(
req
.
getPage
(),
result
));
}
...
...
community-service/src/main/java/com/tanpu/community/controller/HomePageController.java
View file @
a20c600c
...
...
@@ -46,14 +46,12 @@ public class HomePageController {
@Resource
private
UserHolder
userHolder
;
@Resource
HttpServletHelper
httpServletHelper
;
// 用户信息查询 (供圈子服务调用)
@ApiOperation
(
value
=
"个人中心 查询"
)
@GetMapping
(
value
=
"/queryUserInfoNew"
)
public
CommonResp
<
UserInfoResp
>
queryUsersListNew
(
@RequestParam
(
value
=
"userId"
)
String
userId
)
{
String
selfUserId
=
httpServletHelper
.
getCurren
tUserId
();
String
selfUserId
=
userHolder
.
ge
tUserId
();
return
CommonResp
.
success
(
homePageManager
.
queryUsersInfo
(
selfUserId
,
userId
));
}
...
...
@@ -77,7 +75,7 @@ public class HomePageController {
@ApiOperation
(
"查询关注/粉丝列表"
)
@ResponseBody
public
CommonResp
<
Page
<
FollowQo
>>
queryFollowList
(
@RequestBody
QueryFollowReq
req
)
{
String
selfUserId
=
httpServletHelper
.
getCurren
tUserId
();
String
selfUserId
=
userHolder
.
ge
tUserId
();
return
CommonResp
.
success
(
homePageManager
.
queryFollow
(
req
,
selfUserId
));
}
...
...
@@ -95,7 +93,7 @@ public class HomePageController {
@ApiOperation
(
"用户的帖子列表"
)
@ResponseBody
public
CommonResp
<
List
<
ThemeQo
>>
likeList
(
@Validated
@RequestBody
QueryRecordThemeReq
req
)
{
String
selfUserId
=
httpServletHelper
.
getCurren
tUserId
();
String
selfUserId
=
userHolder
.
ge
tUserId
();
return
CommonResp
.
success
(
themeManager
.
queryThemesByUser
(
req
,
selfUserId
));
}
...
...
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