Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
S
saturn
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
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
赵磊
saturn
Commits
eb53409c
Commit
eb53409c
authored
Aug 09, 2019
by
王浩
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'haow/dev' into 'test'
fix code See merge request
alpha/saturn!93
parents
92ecf990
3be054ce
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
2 deletions
+7
-2
pictorial.py
api/views/pictorial.py
+7
-2
No files found.
api/views/pictorial.py
View file @
eb53409c
...
...
@@ -28,8 +28,13 @@ class CreatePictorial(BaseView):
ins_cache
.
delete
(
obj
)
def
get_random_user_id
(
self
):
index
=
randint
(
0
,
5000
)
return
self
.
user_id_start
+
index
while
True
:
index
=
randint
(
0
,
5000
)
user_id
=
self
.
user_id_start
+
index
error
,
data
=
self
.
call_rpc
(
'venus/community/user/is_shadow'
,
user_id
=
user_id
)
ret
=
data
.
get
(
'user_id'
)
if
ret
:
return
user_id
def
get_user_id
(
self
,
id_
,
platform
):
cache_key
=
'grap:{}:{}'
.
format
(
platform
,
id_
)
...
...
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