Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
B
beyond-clouds
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
4
Issues
4
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
段启岩
beyond-clouds
Commits
d54b932c
Commit
d54b932c
authored
Feb 02, 2020
by
胡明森
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
我的话题列表
parent
d59d9d2c
Show whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
33 additions
and
2 deletions
+33
-2
src/main/java/cn/meteor/beyondclouds/modules/topic/api/TopicApi.java
+15
-0
src/main/java/cn/meteor/beyondclouds/modules/topic/service/ITopicService.java
+2
-0
src/main/java/cn/meteor/beyondclouds/modules/topic/service/impl/TopicServiceImpl.java
+8
-0
src/main/resources/application-prod.yml
+4
-1
src/main/resources/application.yml
+4
-1
No files found.
src/main/java/cn/meteor/beyondclouds/modules/topic/api/TopicApi.java
View file @
d54b932c
...
@@ -127,4 +127,19 @@ public class TopicApi {
...
@@ -127,4 +127,19 @@ public class TopicApi {
return
Response
.
success
(
page
);
return
Response
.
success
(
page
);
}
}
/**
* 我创建的话题列表
* @param pageForm
* @return
*/
@ApiOperation
(
"我的话题列表"
)
@GetMapping
(
"/my/topic/created"
)
public
Response
<
PageVO
<
Topic
>>
getMyTopics
(
@Valid
PageForm
pageForm
,
@CurrentSubject
Subject
subject
)
{
// 根据用户获取列表并返回
IPage
<
Topic
>
topicPage
=
topicService
.
getProjectPage
(
pageForm
.
getPage
(),
pageForm
.
getSize
(),
(
String
)
subject
.
getId
());
PageVO
<
Topic
>
topicPageVO
=
new
PageVO
<>(
topicPage
);
return
Response
.
success
(
topicPageVO
);
}
}
}
src/main/java/cn/meteor/beyondclouds/modules/topic/service/ITopicService.java
View file @
d54b932c
...
@@ -63,4 +63,6 @@ public interface ITopicService extends IService<Topic> {
...
@@ -63,4 +63,6 @@ public interface ITopicService extends IService<Topic> {
* @return
* @return
*/
*/
IPage
<
User
>
getTopicsFollower
(
Integer
page
,
Integer
size
,
String
topicId
);
IPage
<
User
>
getTopicsFollower
(
Integer
page
,
Integer
size
,
String
topicId
);
IPage
<
Topic
>
getProjectPage
(
Integer
page
,
Integer
size
,
String
userId
);
}
}
src/main/java/cn/meteor/beyondclouds/modules/topic/service/impl/TopicServiceImpl.java
View file @
d54b932c
...
@@ -175,5 +175,13 @@ public class TopicServiceImpl extends ServiceImpl<TopicMapper, Topic> implements
...
@@ -175,5 +175,13 @@ public class TopicServiceImpl extends ServiceImpl<TopicMapper, Topic> implements
return
userPage
;
return
userPage
;
}
}
@Override
public
IPage
<
Topic
>
getProjectPage
(
Integer
pageNumber
,
Integer
pageSize
,
String
userId
)
{
IPage
<
Topic
>
page
=
new
Page
<>(
pageNumber
,
pageSize
);
QueryWrapper
<
Topic
>
topicQueryWrapper
=
new
QueryWrapper
<>();
topicQueryWrapper
.
eq
(
"user_id"
,
userId
);
return
page
(
page
,
topicQueryWrapper
);
}
}
}
src/main/resources/application-prod.yml
View file @
d54b932c
...
@@ -3,7 +3,7 @@ spring:
...
@@ -3,7 +3,7 @@ spring:
driver-class-name
:
com.mysql.cj.jdbc.Driver
driver-class-name
:
com.mysql.cj.jdbc.Driver
url
:
jdbc:mysql://127.0.0.1:3306/beyond_clouds?useUnicode=true&characterEncoding=UTF-8&useSSL=false&allowPublicKeyRetrieval=true
url
:
jdbc:mysql://127.0.0.1:3306/beyond_clouds?useUnicode=true&characterEncoding=UTF-8&useSSL=false&allowPublicKeyRetrieval=true
username
:
root
username
:
root
password
:
197442
password
:
password
swagger
:
swagger
:
enable
:
true
enable
:
true
...
@@ -33,3 +33,5 @@ beyondclouds:
...
@@ -33,3 +33,5 @@ beyondclouds:
client-id
:
101846021
client-id
:
101846021
client-secret
:
5bc41deeb7e152e2e6aff97726bbf86a
client-secret
:
5bc41deeb7e152e2e6aff97726bbf86a
redirect-uri
:
http://meteor.natapp1.cc/auth/qq
redirect-uri
:
http://meteor.natapp1.cc/auth/qq
server
:
port
:
8081
\ No newline at end of file
src/main/resources/application.yml
View file @
d54b932c
...
@@ -3,7 +3,7 @@ spring:
...
@@ -3,7 +3,7 @@ spring:
driver-class-name
:
com.mysql.cj.jdbc.Driver
driver-class-name
:
com.mysql.cj.jdbc.Driver
url
:
jdbc:mysql://127.0.0.1:3306/beyond_clouds?useUnicode=true&characterEncoding=UTF-8&useSSL=false&allowPublicKeyRetrieval=true
url
:
jdbc:mysql://127.0.0.1:3306/beyond_clouds?useUnicode=true&characterEncoding=UTF-8&useSSL=false&allowPublicKeyRetrieval=true
username
:
root
username
:
root
password
:
100Centa30821%mysql
password
:
password
swagger
:
swagger
:
enable
:
true
enable
:
true
...
@@ -33,3 +33,5 @@ beyondclouds:
...
@@ -33,3 +33,5 @@ beyondclouds:
client-id
:
101846021
client-id
:
101846021
client-secret
:
5bc41deeb7e152e2e6aff97726bbf86a
client-secret
:
5bc41deeb7e152e2e6aff97726bbf86a
redirect-uri
:
http://meteor.natapp1.cc/auth/qq
redirect-uri
:
http://meteor.natapp1.cc/auth/qq
server
:
port
:
8081
\ No newline at end of file
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