mirror of
https://github.com/infiniflow/ragflow.git
synced 2025-12-08 20:42:30 +08:00
### What problem does this PR solve? Fix: Bug fixes #9869 - Adjusted the breadcrumb display logic on the data flow results page - Added the default display of "Local Upload" to the Source field in the dataset overview table - Replaced the original Mindmap Task field with the GraphRAG Task field on the dataset settings page - Optimized the build button status check criteria and adjusted the progress information display logic - Introduced a Tooltip in the parsing status cell component and removed redundant Button components ### Type of change - [x] Bug Fix (non-breaking change which fixes an issue)
This commit is contained in:
@ -33,6 +33,8 @@ export interface IKnowledge {
|
|||||||
raptor_task_id?: string;
|
raptor_task_id?: string;
|
||||||
mindmap_task_finish_at?: string;
|
mindmap_task_finish_at?: string;
|
||||||
mindmap_task_id?: string;
|
mindmap_task_id?: string;
|
||||||
|
graphrag_task_finish_at: string;
|
||||||
|
graphrag_task_id: string;
|
||||||
}
|
}
|
||||||
|
|
||||||
export interface IKnowledgeResult {
|
export interface IKnowledgeResult {
|
||||||
|
|||||||
@ -96,17 +96,18 @@ export default {
|
|||||||
description: 'Which knowledge bases will you use today?',
|
description: 'Which knowledge bases will you use today?',
|
||||||
createKnowledgeBase: 'Create Dataset',
|
createKnowledgeBase: 'Create Dataset',
|
||||||
name: 'Name',
|
name: 'Name',
|
||||||
namePlaceholder: 'Please input name!',
|
namePlaceholder: 'Please input name.',
|
||||||
doc: 'Docs',
|
doc: 'Docs',
|
||||||
searchKnowledgePlaceholder: 'Search',
|
searchKnowledgePlaceholder: 'Search',
|
||||||
noMoreData: `That's all. Nothing more.`,
|
noMoreData: `That's all. Nothing more.`,
|
||||||
},
|
},
|
||||||
knowledgeDetails: {
|
knowledgeDetails: {
|
||||||
|
localUpload: 'Local Upload',
|
||||||
fileSize: 'File Size',
|
fileSize: 'File Size',
|
||||||
fileType: 'File Type',
|
fileType: 'File Type',
|
||||||
uploadedBy: 'Uploaded by',
|
uploadedBy: 'Uploaded by',
|
||||||
notGenerated: 'Not generated',
|
notGenerated: 'Not generated',
|
||||||
generatedOn: 'Generated on',
|
generatedOn: 'Generated on ',
|
||||||
subbarFiles: 'Files',
|
subbarFiles: 'Files',
|
||||||
generateKnowledgeGraph:
|
generateKnowledgeGraph:
|
||||||
'This will extract entities and relationships from all your documents in this dataset. The process may take a while to complete.',
|
'This will extract entities and relationships from all your documents in this dataset. The process may take a while to complete.',
|
||||||
|
|||||||
@ -94,6 +94,7 @@ export default {
|
|||||||
noMoreData: '没有更多数据了',
|
noMoreData: '没有更多数据了',
|
||||||
},
|
},
|
||||||
knowledgeDetails: {
|
knowledgeDetails: {
|
||||||
|
localUpload: '本地上传',
|
||||||
fileSize: '文件大小',
|
fileSize: '文件大小',
|
||||||
fileType: '文件类型',
|
fileType: '文件类型',
|
||||||
uploadedBy: '创建者',
|
uploadedBy: '创建者',
|
||||||
|
|||||||
@ -187,7 +187,9 @@ const Chunk = () => {
|
|||||||
</BreadcrumbItem>
|
</BreadcrumbItem>
|
||||||
<BreadcrumbSeparator />
|
<BreadcrumbSeparator />
|
||||||
<BreadcrumbItem>
|
<BreadcrumbItem>
|
||||||
<BreadcrumbPage>{documentInfo?.name}</BreadcrumbPage>
|
<BreadcrumbPage>
|
||||||
|
{knowledgeId ? documentInfo?.name : t('dataflow.viewResult')}
|
||||||
|
</BreadcrumbPage>
|
||||||
</BreadcrumbItem>
|
</BreadcrumbItem>
|
||||||
</BreadcrumbList>
|
</BreadcrumbList>
|
||||||
</Breadcrumb>
|
</Breadcrumb>
|
||||||
|
|||||||
@ -94,7 +94,9 @@ export const getFileLogsTableColumns = (
|
|||||||
accessorKey: 'source_from',
|
accessorKey: 'source_from',
|
||||||
header: t('source'),
|
header: t('source'),
|
||||||
cell: ({ row }) => (
|
cell: ({ row }) => (
|
||||||
<div className="text-text-primary">{row.original.source_from}</div>
|
<div className="text-text-primary">
|
||||||
|
{row.original.source_from || t('localUpload')}
|
||||||
|
</div>
|
||||||
),
|
),
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|||||||
@ -95,8 +95,8 @@ export default function DatasetSettings() {
|
|||||||
};
|
};
|
||||||
setPipelineData(data);
|
setPipelineData(data);
|
||||||
setGraphRagGenerateData({
|
setGraphRagGenerateData({
|
||||||
finish_at: knowledgeDetails.mindmap_task_finish_at,
|
finish_at: knowledgeDetails.graphrag_task_finish_at,
|
||||||
task_id: knowledgeDetails.mindmap_task_id,
|
task_id: knowledgeDetails.graphrag_task_id,
|
||||||
} as IGenerateLogButtonProps);
|
} as IGenerateLogButtonProps);
|
||||||
setRaptorGenerateData({
|
setRaptorGenerateData({
|
||||||
finish_at: knowledgeDetails.raptor_task_finish_at,
|
finish_at: knowledgeDetails.raptor_task_finish_at,
|
||||||
|
|||||||
@ -116,7 +116,8 @@ const MenuItem: React.FC<{
|
|||||||
/>
|
/>
|
||||||
{t(`knowledgeDetails.${lowerFirst(type)}`)}
|
{t(`knowledgeDetails.${lowerFirst(type)}`)}
|
||||||
</div>
|
</div>
|
||||||
{status === generateStatus.start && (
|
{(status === generateStatus.start ||
|
||||||
|
status === generateStatus.completed) && (
|
||||||
<div className="text-text-secondary text-sm">
|
<div className="text-text-secondary text-sm">
|
||||||
{t(`knowledgeDetails.generate${type}`)}
|
{t(`knowledgeDetails.generate${type}`)}
|
||||||
</div>
|
</div>
|
||||||
@ -165,9 +166,12 @@ const MenuItem: React.FC<{
|
|||||||
)}
|
)}
|
||||||
</div>
|
</div>
|
||||||
)}
|
)}
|
||||||
<div className="w-full whitespace-pre-line text-wrap rounded-lg h-fit max-h-[350px] overflow-y-auto scrollbar-auto px-2.5 py-1">
|
{status !== generateStatus.start &&
|
||||||
{replaceText(data?.progress_msg || '')}
|
status !== generateStatus.completed && (
|
||||||
</div>
|
<div className="w-full whitespace-pre-line text-wrap rounded-lg h-fit max-h-[350px] overflow-y-auto scrollbar-auto px-2.5 py-1">
|
||||||
|
{replaceText(data?.progress_msg || '')}
|
||||||
|
</div>
|
||||||
|
)}
|
||||||
</div>
|
</div>
|
||||||
</DropdownMenuItem>
|
</DropdownMenuItem>
|
||||||
);
|
);
|
||||||
|
|||||||
@ -1,6 +1,5 @@
|
|||||||
import { ConfirmDeleteDialog } from '@/components/confirm-delete-dialog';
|
import { ConfirmDeleteDialog } from '@/components/confirm-delete-dialog';
|
||||||
import { IconFontFill } from '@/components/icon-font';
|
import { IconFontFill } from '@/components/icon-font';
|
||||||
import { Button } from '@/components/ui/button';
|
|
||||||
import {
|
import {
|
||||||
DropdownMenu,
|
DropdownMenu,
|
||||||
DropdownMenuContent,
|
DropdownMenuContent,
|
||||||
@ -9,6 +8,11 @@ import {
|
|||||||
} from '@/components/ui/dropdown-menu';
|
} from '@/components/ui/dropdown-menu';
|
||||||
import { Progress } from '@/components/ui/progress';
|
import { Progress } from '@/components/ui/progress';
|
||||||
import { Separator } from '@/components/ui/separator';
|
import { Separator } from '@/components/ui/separator';
|
||||||
|
import {
|
||||||
|
Tooltip,
|
||||||
|
TooltipContent,
|
||||||
|
TooltipTrigger,
|
||||||
|
} from '@/components/ui/tooltip';
|
||||||
import { IDocumentInfo } from '@/interfaces/database/document';
|
import { IDocumentInfo } from '@/interfaces/database/document';
|
||||||
import { CircleX } from 'lucide-react';
|
import { CircleX } from 'lucide-react';
|
||||||
import { useCallback, useMemo } from 'react';
|
import { useCallback, useMemo } from 'react';
|
||||||
@ -86,16 +90,29 @@ export function ParsingStatusCell({
|
|||||||
};
|
};
|
||||||
return (
|
return (
|
||||||
<section className="flex gap-8 items-center">
|
<section className="flex gap-8 items-center">
|
||||||
<div className="w-[100px] text-ellipsis overflow-hidden flex items-center justify-between">
|
<div className="text-ellipsis w-[100px] flex items-center justify-between">
|
||||||
<DropdownMenu>
|
<DropdownMenu>
|
||||||
<DropdownMenuTrigger asChild>
|
<DropdownMenuTrigger>
|
||||||
<Button variant={'transparent'} className="border-none" size={'sm'}>
|
<Tooltip>
|
||||||
{pipeline_id
|
<TooltipTrigger asChild>
|
||||||
? pipeline_name || pipeline_id
|
<div className="border-none truncate max-w-32 cursor-pointer px-2 py-1 rounded-sm hover:bg-bg-card">
|
||||||
: parser_id === 'naive'
|
{pipeline_id
|
||||||
? 'general'
|
? pipeline_name || pipeline_id
|
||||||
: parser_id}
|
: parser_id === 'naive'
|
||||||
</Button>
|
? 'general'
|
||||||
|
: parser_id}
|
||||||
|
</div>
|
||||||
|
</TooltipTrigger>
|
||||||
|
<TooltipContent>
|
||||||
|
<p>
|
||||||
|
{pipeline_id
|
||||||
|
? pipeline_name || pipeline_id
|
||||||
|
: parser_id === 'naive'
|
||||||
|
? 'general'
|
||||||
|
: parser_id}
|
||||||
|
</p>
|
||||||
|
</TooltipContent>
|
||||||
|
</Tooltip>
|
||||||
</DropdownMenuTrigger>
|
</DropdownMenuTrigger>
|
||||||
<DropdownMenuContent>
|
<DropdownMenuContent>
|
||||||
<DropdownMenuItem onClick={handleShowChangeParserModal}>
|
<DropdownMenuItem onClick={handleShowChangeParserModal}>
|
||||||
@ -107,6 +124,7 @@ export function ParsingStatusCell({
|
|||||||
</DropdownMenuContent>
|
</DropdownMenuContent>
|
||||||
</DropdownMenu>
|
</DropdownMenu>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
{showParse && (
|
{showParse && (
|
||||||
<div className="flex items-center gap-3">
|
<div className="flex items-center gap-3">
|
||||||
<Separator orientation="vertical" className="h-2.5" />
|
<Separator orientation="vertical" className="h-2.5" />
|
||||||
|
|||||||
Reference in New Issue
Block a user