mirror of
https://git.mirrors.martin98.com/https://github.com/infiniflow/ragflow.git
synced 2025-05-29 17:45:33 +08:00
### What problem does this PR solve? fix: Chunks cannot be deleted #1912 ### Type of change - [x] Bug Fix (non-breaking change which fixes an issue)
This commit is contained in:
parent
68d1315079
commit
936d8ab7dd
@ -124,7 +124,7 @@ export const useDeleteChunk = () => {
|
||||
mutateAsync,
|
||||
} = useMutation({
|
||||
mutationKey: ['deleteChunk'],
|
||||
mutationFn: async (params: { chunkIds: string[]; documentId: string }) => {
|
||||
mutationFn: async (params: { chunkIds: string[]; doc_id: string }) => {
|
||||
const { data } = await kbService.rm_chunk(params);
|
||||
if (data.retcode === 0) {
|
||||
setPaginationParams(1);
|
||||
|
@ -67,7 +67,7 @@ export const useDeleteChunkByIds = (): {
|
||||
|
||||
const removeChunk = useCallback(
|
||||
(chunkIds: string[], documentId: string) => () => {
|
||||
return deleteChunk({ chunkIds, documentId });
|
||||
return deleteChunk({ chunkIds, doc_id: documentId });
|
||||
},
|
||||
[deleteChunk],
|
||||
);
|
||||
|
Loading…
x
Reference in New Issue
Block a user