| | |
| | | import StatusWithAction from './status-with-action' |
| | | import { getErrorDocs, retryErrorDocs } from '@/service/datasets' |
| | | import type { IndexingStatusResponse } from '@/models/datasets' |
| | | import { noop } from 'lodash-es' |
| | | |
| | | type Props = { |
| | | datasetId: string |
| | |
| | | description={`${errorDocs?.total} ${t('dataset.docsFailedNotice')}`} |
| | | actionText={t('dataset.retry')} |
| | | disabled={indexState.value === 'retry'} |
| | | onAction={indexState.value === 'error' ? onRetryErrorDocs : noop} |
| | | onAction={indexState.value === 'error' ? onRetryErrorDocs : () => { }} |
| | | /> |
| | | ) |
| | | } |