fix: Application deleted, workflow page error reported (#2743)
This commit is contained in:
parent
b3feb243d3
commit
1566ae7fbe
@ -1209,7 +1209,9 @@ class ApplicationSerializer(serializers.Serializer):
|
|||||||
self.is_valid(raise_exception=True)
|
self.is_valid(raise_exception=True)
|
||||||
if with_valid:
|
if with_valid:
|
||||||
self.is_valid()
|
self.is_valid()
|
||||||
embed_application = QuerySet(Application).get(id=app_id)
|
embed_application = QuerySet(Application).filter(id=app_id).first()
|
||||||
|
if embed_application is None:
|
||||||
|
raise AppApiException(500, _('Application does not exist'))
|
||||||
if embed_application.type == ApplicationTypeChoices.WORK_FLOW:
|
if embed_application.type == ApplicationTypeChoices.WORK_FLOW:
|
||||||
work_flow_version = QuerySet(WorkFlowVersion).filter(application_id=embed_application.id).order_by(
|
work_flow_version = QuerySet(WorkFlowVersion).filter(application_id=embed_application.id).order_by(
|
||||||
'-create_time')[0:1].first()
|
'-create_time')[0:1].first()
|
||||||
@ -1332,4 +1334,3 @@ class ApplicationSerializer(serializers.Serializer):
|
|||||||
}
|
}
|
||||||
for tool in asyncio.run(get_mcp_tools({server: servers[server]}))]
|
for tool in asyncio.run(get_mcp_tools({server: servers[server]}))]
|
||||||
return tools
|
return tools
|
||||||
|
|
||||||
|
|||||||
@ -146,10 +146,9 @@
|
|||||||
<template #label>
|
<template #label>
|
||||||
<div class="flex align-center">
|
<div class="flex align-center">
|
||||||
<div class="mr-4">
|
<div class="mr-4">
|
||||||
<span
|
<span>{{
|
||||||
>{{ $t('views.applicationWorkflow.nodes.aiChatNode.returnContent.label')
|
$t('views.applicationWorkflow.nodes.aiChatNode.returnContent.label')
|
||||||
}}</span
|
}}</span>
|
||||||
>
|
|
||||||
</div>
|
</div>
|
||||||
<el-tooltip effect="dark" placement="right" popper-class="max-w-200">
|
<el-tooltip effect="dark" placement="right" popper-class="max-w-200">
|
||||||
<template #content>
|
<template #content>
|
||||||
@ -288,7 +287,7 @@ const update_field = () => {
|
|||||||
}
|
}
|
||||||
})
|
})
|
||||||
.catch((err) => {
|
.catch((err) => {
|
||||||
// set(props.nodeModel.properties, 'status', 500)
|
set(props.nodeModel.properties, 'status', 500)
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user