Fix: Clicking the checkbox of the pop-up window for editing chunk is invalid #3726 (#3727)

### What problem does this PR solve?

Fix: Clicking the checkbox of the pop-up window for editing chunk is
invalid #3726

### Type of change

- [x] Bug Fix (non-breaking change which fixes an issue)
This commit is contained in:
balibabu
2024-11-28 20:08:06 +08:00
committed by GitHub
parent 80af3cc2d4
commit a3e0ac9c0b
4 changed files with 27 additions and 9 deletions

View File

@ -95,12 +95,21 @@ export const useUpdateChunk = () => {
const { documentId } = useGetKnowledgeSearchParams();
const onChunkUpdatingOk = useCallback(
async ({ content, keywords }: { content: string; keywords: string }) => {
async ({
content,
keywords,
available_int,
}: {
content: string;
keywords: string;
available_int: number;
}) => {
const code = await createChunk({
content_with_weight: content,
doc_id: documentId,
chunk_id: chunkId,
important_kwd: keywords, // keywords
available_int,
});
if (code === 0) {