mirror of
https://github.com/langgenius/dify.git
synced 2026-05-05 17:18:40 +08:00
fix preview run
This commit is contained in:
parent
d0dd728e6c
commit
5cf795f2b8
@ -202,6 +202,7 @@ class DatasourceNode(Node):
|
|||||||
related_id=upload_file.id,
|
related_id=upload_file.id,
|
||||||
size=upload_file.size,
|
size=upload_file.size,
|
||||||
storage_key=upload_file.key,
|
storage_key=upload_file.key,
|
||||||
|
url=upload_file.source_url,
|
||||||
)
|
)
|
||||||
variable_pool.add([self._node_id, "file"], file_info)
|
variable_pool.add([self._node_id, "file"], file_info)
|
||||||
# variable_pool.add([self.node_id, "file"], file_info.to_dict())
|
# variable_pool.add([self.node_id, "file"], file_info.to_dict())
|
||||||
|
|||||||
@ -345,7 +345,7 @@ def _build_from_datasource_file(
|
|||||||
)
|
)
|
||||||
|
|
||||||
return File(
|
return File(
|
||||||
id=mapping.get("id"),
|
id=mapping.get("datasource_file_id"),
|
||||||
tenant_id=tenant_id,
|
tenant_id=tenant_id,
|
||||||
filename=datasource_file.name,
|
filename=datasource_file.name,
|
||||||
type=file_type,
|
type=file_type,
|
||||||
@ -356,6 +356,7 @@ def _build_from_datasource_file(
|
|||||||
mime_type=datasource_file.mime_type,
|
mime_type=datasource_file.mime_type,
|
||||||
size=datasource_file.size,
|
size=datasource_file.size,
|
||||||
storage_key=datasource_file.key,
|
storage_key=datasource_file.key,
|
||||||
|
url=datasource_file.source_url,
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user