Skip to content

armgit / dify

Public Imported from GitHub
0

Build Agentic workflows, RAG pipelines, with rich AI model and tool support on one collaborative workspace. Deploy on cloud, VPC, or self-hosted, so teams move from prototype to production without rebuilding the stack.

fix: tags could not be saved when the Workflow Tool was created (#11481)

zhaobingshuang5c166b3f409f
diff --git a/api/controllers/console/workspace/tool_providers.py b/api/controllers/console/workspace/tool_providers.py
index 9ecda2126d4..2cd6dcda3b5 100644
--- a/api/controllers/console/workspace/tool_providers.py
+++ b/api/controllers/console/workspace/tool_providers.py
@@ -368,6 +368,7 @@ class ToolWorkflowProviderCreateApi(Resource):
description=args["description"],
parameters=args["parameters"],
privacy_policy=args["privacy_policy"],
+ labels=args["labels"],
)
diff --git a/api/services/tools/workflow_tools_manage_service.py b/api/services/tools/workflow_tools_manage_service.py
index 833881b668b..318107bebb5 100644
--- a/api/services/tools/workflow_tools_manage_service.py
+++ b/api/services/tools/workflow_tools_manage_service.py
@@ -81,6 +81,10 @@ class WorkflowToolManageService:
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