mirror of
https://github.com/infiniflow/ragflow.git
synced 2025-12-31 17:15:32 +08:00
Fix: frontend cannot sync document window context (#12256)
### What problem does this PR solve? Frontend cannot sync document window context. ### Type of change - [x] Bug Fix (non-breaking change which fixes an issue) Co-authored-by: Liu An <asiro@qq.com>
This commit is contained in:
@ -220,12 +220,15 @@ export function ChunkMethodDialog({
|
|||||||
|
|
||||||
async function onSubmit(data: z.infer<typeof FormSchema>) {
|
async function onSubmit(data: z.infer<typeof FormSchema>) {
|
||||||
console.log('🚀 ~ onSubmit ~ data:', data);
|
console.log('🚀 ~ onSubmit ~ data:', data);
|
||||||
const { image_table_context_window, ...parserConfig } = data.parser_config;
|
const parserConfig = data.parser_config;
|
||||||
const imageTableContextWindow = Number(image_table_context_window || 0);
|
const imageTableContextWindow = Number(
|
||||||
|
parserConfig?.image_table_context_window || 0,
|
||||||
|
);
|
||||||
const nextData = {
|
const nextData = {
|
||||||
...data,
|
...data,
|
||||||
parser_config: {
|
parser_config: {
|
||||||
...parserConfig,
|
...parserConfig,
|
||||||
|
image_table_context_window: imageTableContextWindow,
|
||||||
image_context_size: imageTableContextWindow,
|
image_context_size: imageTableContextWindow,
|
||||||
table_context_size: imageTableContextWindow,
|
table_context_size: imageTableContextWindow,
|
||||||
// Unset children delimiter if this option is not enabled
|
// Unset children delimiter if this option is not enabled
|
||||||
|
|||||||
@ -73,6 +73,8 @@ export function SavingButton() {
|
|||||||
...values,
|
...values,
|
||||||
parser_config: {
|
parser_config: {
|
||||||
...values.parser_config,
|
...values.parser_config,
|
||||||
|
image_table_context_window:
|
||||||
|
values.parser_config.image_table_context_window,
|
||||||
image_context_size:
|
image_context_size:
|
||||||
values.parser_config.image_table_context_window,
|
values.parser_config.image_table_context_window,
|
||||||
table_context_size:
|
table_context_size:
|
||||||
|
|||||||
Reference in New Issue
Block a user