Skip to content

Commit

Permalink
fix: tags could not be saved when the Workflow Tool was created (#11481)
Browse files Browse the repository at this point in the history
Co-authored-by: zhaobs <[email protected]>
  • Loading branch information
zhaobingshuang and zhaobs authored Dec 9, 2024
1 parent 230fa32 commit 5c166b3
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 0 deletions.
1 change: 1 addition & 0 deletions api/controllers/console/workspace/tool_providers.py
Original file line number Diff line number Diff line change
Expand Up @@ -368,6 +368,7 @@ def post(self):
description=args["description"],
parameters=args["parameters"],
privacy_policy=args["privacy_policy"],
labels=args["labels"],
)


Expand Down
4 changes: 4 additions & 0 deletions api/services/tools/workflow_tools_manage_service.py
Original file line number Diff line number Diff line change
Expand Up @@ -81,6 +81,10 @@ def create_workflow_tool(
db.session.add(workflow_tool_provider)
db.session.commit()

if labels is not None:
ToolLabelManager.update_tool_labels(
ToolTransformService.workflow_provider_to_controller(workflow_tool_provider), labels
)
return {"result": "success"}

@classmethod
Expand Down

0 comments on commit 5c166b3

Please sign in to comment.