Fix: The dataset on the list page cannot be renamed. (#13886)

### What problem does this PR solve?

Fix: The dataset on the list page cannot be renamed.

### Type of change

- [x] Bug Fix (non-breaking change which fixes an issue)
This commit is contained in:
balibabu
2026-04-01 20:53:05 +08:00
committed by GitHub
parent b622c47ed6
commit af40be68c3

View File

@@ -1,7 +1,6 @@
import { useSetModalState } from '@/hooks/common-hooks';
import { useUpdateKnowledge } from '@/hooks/use-knowledge-request';
import { IKnowledge } from '@/interfaces/database/knowledge';
import { omit } from 'lodash';
import { useCallback, useState } from 'react';
export const useRenameDataset = () => {
@@ -16,13 +15,6 @@ export const useRenameDataset = () => {
const onDatasetRenameOk = useCallback(
async (name: string) => {
const ret = await saveKnowledgeConfiguration({
...omit(dataset, [
'id',
'update_time',
'nickname',
'tenant_avatar',
'tenant_id',
]),
kb_id: dataset.id,
name,
});