| 
														 | 
														 | 
														 | 
														 | 
														 | 
													
													
												
													
														 | 
														 | 
														    } | 
														 | 
														 | 
														    } | 
													
													
												
													
														 | 
														 | 
														    if (datasourceType === DatasourceType.onlineDrive) { | 
														 | 
														 | 
														    if (datasourceType === DatasourceType.onlineDrive) { | 
													
													
												
													
														 | 
														 | 
														      const { bucket } = dataSourceStore.getState() | 
														 | 
														 | 
														      const { bucket } = dataSourceStore.getState() | 
													
													
												
													
														 | 
														 | 
														      const { id } = previewOnlineDriveFileRef.current! | 
														 | 
														 | 
														 | 
													
													
												
													
														 | 
														 | 
														 | 
														 | 
														 | 
														      const { id, type } = previewOnlineDriveFileRef.current! | 
													
													
												
													
														 | 
														 | 
														      datasourceInfoList.push({ | 
														 | 
														 | 
														      datasourceInfoList.push({ | 
													
													
												
													
														 | 
														 | 
														        bucket, | 
														 | 
														 | 
														        bucket, | 
													
													
												
													
														 | 
														 | 
														        id, | 
														 | 
														 | 
														        id, | 
													
													
												
													
														 | 
														 | 
														 | 
														 | 
														 | 
														        type, | 
													
													
												
													
														 | 
														 | 
														        credential_id: currentCredentialId, | 
														 | 
														 | 
														        credential_id: currentCredentialId, | 
													
													
												
													
														 | 
														 | 
														      }) | 
														 | 
														 | 
														      }) | 
													
													
												
													
														 | 
														 | 
														    } | 
														 | 
														 | 
														    } | 
													
													
												
											
												
													
														 | 
														 | 
														 | 
														 | 
														 | 
														 | 
													
													
												
													
														 | 
														 | 
														  const handleProcess = useCallback(async (data: Record<string, any>) => { | 
														 | 
														 | 
														  const handleProcess = useCallback(async (data: Record<string, any>) => { | 
													
													
												
													
														 | 
														 | 
														    if (!datasource) | 
														 | 
														 | 
														    if (!datasource) | 
													
													
												
													
														 | 
														 | 
														      return | 
														 | 
														 | 
														      return | 
													
													
												
													
														 | 
														 | 
														    const { bucket, currentCredentialId } = dataSourceStore.getState() | 
														 | 
														 | 
														 | 
													
													
												
													
														 | 
														 | 
														 | 
														 | 
														 | 
														    const { bucket, currentCredentialId, fileList: onlineDriveFileList } = dataSourceStore.getState() | 
													
													
												
													
														 | 
														 | 
														    const datasourceInfoList: Record<string, any>[] = [] | 
														 | 
														 | 
														    const datasourceInfoList: Record<string, any>[] = [] | 
													
													
												
													
														 | 
														 | 
														    if (datasourceType === DatasourceType.localFile) { | 
														 | 
														 | 
														    if (datasourceType === DatasourceType.localFile) { | 
													
													
												
													
														 | 
														 | 
														      fileList.forEach((file) => { | 
														 | 
														 | 
														      fileList.forEach((file) => { | 
													
													
												
											
												
													
														 | 
														 | 
														 | 
														 | 
														 | 
														 | 
													
													
												
													
														 | 
														 | 
														    } | 
														 | 
														 | 
														    } | 
													
													
												
													
														 | 
														 | 
														    if (datasourceType === DatasourceType.onlineDrive) { | 
														 | 
														 | 
														    if (datasourceType === DatasourceType.onlineDrive) { | 
													
													
												
													
														 | 
														 | 
														      if (datasourceType === DatasourceType.onlineDrive) { | 
														 | 
														 | 
														      if (datasourceType === DatasourceType.onlineDrive) { | 
													
													
												
													
														 | 
														 | 
														        selectedFileIds.forEach((key) => { | 
														 | 
														 | 
														 | 
													
													
												
													
														 | 
														 | 
														 | 
														 | 
														 | 
														        selectedFileIds.forEach((id) => { | 
													
													
												
													
														 | 
														 | 
														 | 
														 | 
														 | 
														          const file = onlineDriveFileList.find(file => file.id === id) | 
													
													
												
													
														 | 
														 | 
														          datasourceInfoList.push({ | 
														 | 
														 | 
														          datasourceInfoList.push({ | 
													
													
												
													
														 | 
														 | 
														            bucket, | 
														 | 
														 | 
														            bucket, | 
													
													
												
													
														 | 
														 | 
														            key, | 
														 | 
														 | 
														 | 
													
													
												
													
														 | 
														 | 
														 | 
														 | 
														 | 
														            id: file?.id, | 
													
													
												
													
														 | 
														 | 
														 | 
														 | 
														 | 
														            type: file?.type, | 
													
													
												
													
														 | 
														 | 
														            credential_id: currentCredentialId, | 
														 | 
														 | 
														            credential_id: currentCredentialId, | 
													
													
												
													
														 | 
														 | 
														          }) | 
														 | 
														 | 
														          }) | 
													
													
												
													
														 | 
														 | 
														        }) | 
														 | 
														 | 
														        }) |