Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
S
sun
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
1
Merge Requests
1
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
alpha
sun
Commits
348c366c
Commit
348c366c
authored
Dec 03, 2018
by
Davve
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
完善推送
parent
f52d7227
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
5 additions
and
2 deletions
+5
-2
group.py
api/group.py
+1
-1
push.py
api/push.py
+3
-1
topic.py
api/topic.py
+1
-0
No files found.
api/group.py
View file @
348c366c
...
...
@@ -82,7 +82,7 @@ class GroupRelatedUser(APIView):
count
=
int
(
request
.
GET
.
get
(
'limit'
,
10
))
filters
=
{
'group_id'
:
id
}
try
:
data
=
self
.
rpc
[
'venus/sun/group/user/list'
](
filters
=
filters
,
offset
=
offse
t
,
limit
=
count
)
.
unwrap
()
data
=
self
.
rpc
[
'venus/sun/group/user/list'
](
filters
=
filters
,
offset
=
(
offset
-
1
)
*
coun
t
,
limit
=
count
)
.
unwrap
()
except
Exception
as
e
:
raise
e
return
data
...
...
api/push.py
View file @
348c366c
...
...
@@ -32,9 +32,11 @@ class PushUpdateOrCreateView(APIView):
id
=
request
.
POST
.
get
(
'id'
,
''
)
creator_id
=
request
.
POST
.
get
(
'creator_id'
)
push_time
=
analysis_time
(
request
.
POST
.
get
(
'push_time'
,
0
))
group_topic_id
=
request
.
POST
.
get
(
'group_topic_id'
,
''
)
full_url
=
request
.
POST
.
get
(
'url'
,
''
)
+
group_topic_id
data
=
{
'url'
:
request
.
POST
.
get
(
'url'
,
''
)
,
'url'
:
full_url
,
'push_time'
:
push_time
,
'icon'
:
request
.
POST
.
get
(
'icon'
,
''
)[:
-
2
],
'content'
:
request
.
POST
.
get
(
'content'
,
''
),
...
...
api/topic.py
View file @
348c366c
...
...
@@ -52,6 +52,7 @@ class TopicUpdateOrCreateView(APIView):
'user_id'
:
request
.
POST
.
get
(
'user'
,
''
)
.
split
(
':'
)[
0
],
'star_id'
:
request
.
POST
.
get
(
'star'
,
''
)
.
split
(
':'
)[
0
],
'tag_ids'
:
tag_ids
,
'is_online'
:
int
(
request
.
POST
.
get
(
'is_online'
)),
}
try
:
self
.
rpc
[
'venus/sun/topic/edit'
](
id
=
id
,
data
=
data
)
.
unwrap
()
...
...
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