feat: add label field to tool serializer and SQL queries
This commit is contained in:
parent
e13bd094fa
commit
63abffec3c
@ -102,7 +102,7 @@ class ToolModelSerializer(serializers.ModelSerializer):
|
|||||||
class Meta:
|
class Meta:
|
||||||
model = Tool
|
model = Tool
|
||||||
fields = ['id', 'name', 'icon', 'desc', 'code', 'input_field_list', 'init_field_list', 'init_params',
|
fields = ['id', 'name', 'icon', 'desc', 'code', 'input_field_list', 'init_field_list', 'init_params',
|
||||||
'scope', 'is_active', 'user_id', 'template_id', 'workspace_id', 'folder_id', 'tool_type',
|
'scope', 'is_active', 'user_id', 'template_id', 'workspace_id', 'folder_id', 'tool_type', 'label',
|
||||||
'create_time', 'update_time']
|
'create_time', 'update_time']
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@ -10,6 +10,7 @@ from (select tool."id"::text,
|
|||||||
tool."user_id",
|
tool."user_id",
|
||||||
"user".nick_name as "nick_name",
|
"user".nick_name as "nick_name",
|
||||||
tool."icon",
|
tool."icon",
|
||||||
|
tool.label,
|
||||||
tool."template_id"::text,
|
tool."template_id"::text,
|
||||||
tool."create_time",
|
tool."create_time",
|
||||||
tool."update_time",
|
tool."update_time",
|
||||||
@ -30,6 +31,7 @@ from (select tool."id"::text,
|
|||||||
tool_folder."user_id",
|
tool_folder."user_id",
|
||||||
"user".nick_name as "nick_name",
|
"user".nick_name as "nick_name",
|
||||||
'' as "icon",
|
'' as "icon",
|
||||||
|
'' as label,
|
||||||
'' as "template_id",
|
'' as "template_id",
|
||||||
tool_folder."create_time",
|
tool_folder."create_time",
|
||||||
tool_folder."update_time",
|
tool_folder."update_time",
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user