From 34772bd3b4a3353e72c9d32dbdcde7ad167ea8ad Mon Sep 17 00:00:00 2001 From: smanylov Date: Thu, 30 Apr 2026 11:59:06 +0700 Subject: [PATCH] add check_similar_first for global search --- src/app/actions/searchActions.ts | 41 +------------------------------- 1 file changed, 1 insertion(+), 40 deletions(-) diff --git a/src/app/actions/searchActions.ts b/src/app/actions/searchActions.ts index 965cab8..c7191ce 100644 --- a/src/app/actions/searchActions.ts +++ b/src/app/actions/searchActions.ts @@ -41,46 +41,6 @@ export async function searchGlobalFiles(fileId: string, currentPage: number) { const token = await getSessionData('token'); //удалить когда поиск будет нормально работать - /* return { - images: [ - { - url: 'string1', - pageTitle: `string1 from page ${currentPage}`, - height: 100, - width: 100, - host: 'string1', - pageUrl: 'string1' - }, - { - url: 'string1', - pageTitle: `string2 from page ${currentPage}`, - height: 100, - width: 100, - host: 'string1', - pageUrl: 'string1' - }, - { - url: 'string1', - pageTitle: `string3 from page ${currentPage}`, - height: 100, - width: 100, - host: 'string1', - pageUrl: 'string1' - } - ], - page: 0, - pageSize: 0, - totalPages: 11, - totalResults: 100, - } */ - - /* return { - images: [], - page: 0, - pageSize: 0, - totalPages: 0, - totalResults: 0 - } */ try { const response = await fetch(`${API_BASE_URL}/api/v1/data`, { @@ -91,6 +51,7 @@ export async function searchGlobalFiles(fileId: string, currentPage: number) { message_body: { file_id: fileId, page: currentPage, + check_similar_first: true, } }), headers: {