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
eef6be89
Commit
eef6be89
authored
May 23, 2019
by
杨成林
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'ycl/fix' into 'test'
fix tag create See merge request
alpha/saturn!51
parents
6c5c085c
5cf9c369
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
3 deletions
+4
-3
topic.py
api/views/topic.py
+4
-3
No files found.
api/views/topic.py
View file @
eef6be89
...
...
@@ -112,7 +112,9 @@ class CreateTopicForBatch(BaseView):
)
if
_tag_error
:
return
self
.
error
(
_tag_error
)
_tag_data
.
update
(
location_tags
)
for
item
in
location_tags
:
_tag_data
.
update
(
item
)
# 更新发帖
# 处理标签,将文本中的标签处理成现有标签
...
...
@@ -197,12 +199,11 @@ class CreateTopicForBatchByOne(BaseView):
# check_info = Sensitive.check(tag_names)
# tags = [tag_name for tag_name, succ in check_info.items() if not succ]
# check_info = Sensitive.check(tag_names)
tags
=
[{
"name"
:
item
}
for
item
in
tag_names
]
# 先创建标签
_tag_error
,
_tag_data
=
self
.
call_rpc
(
"venus/community/tag/batch_create_tag_by_name"
,
tags
=
tags
tags
=
tag
_name
s
)
if
_tag_error
:
return
self
.
error
(
_tag_error
)
...
...
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