mirror of
https://github.com/langgenius/dify.git
synced 2026-05-05 09:58:04 +08:00
refactor: enhance datasource handling by adding fileExtensions support
This commit is contained in:
@ -36,6 +36,7 @@ export const useDatasourceOptions = (pipelineNodes: Node<DataSourceNodeType>[])
|
||||
description: node.data.desc || '',
|
||||
docTitle: '', // todo: Add docTitle and docLink if needed, or remove these properties if not used
|
||||
docLink: '',
|
||||
fileExtensions: node.data.fileExtensions || [],
|
||||
}
|
||||
})
|
||||
}, [datasourceNodes])
|
||||
|
||||
@ -265,6 +265,7 @@ const TestRunPanel = () => {
|
||||
{datasource?.type === DatasourceType.localFile && (
|
||||
<LocalFile
|
||||
files={fileList}
|
||||
allowedExtensions={datasource?.fileExtensions || []}
|
||||
updateFile={updateFile}
|
||||
updateFileList={updateFileList}
|
||||
onPreview={updateCurrentFile}
|
||||
|
||||
Reference in New Issue
Block a user