fix sorting for document view

This commit is contained in:
smanylov
2026-05-16 16:56:31 +07:00
parent d0793a281e
commit 210145f5ca
3 changed files with 51 additions and 17 deletions
+10 -2
View File
@@ -166,7 +166,13 @@ export async function filePermisionChange(fileId: string, permissions: boolean)
}
}
export async function fetchHistoryView(page: number, size: number, locale: string) {
export async function fetchHistoryView(
page: number,
size: number,
locale: string,
sortDirection?: 'asc' | 'desc',
sortBy?: string
) {
const token = await getSessionData('token');
try {
@@ -180,7 +186,9 @@ export async function fetchHistoryView(page: number, size: number, locale: strin
action: 'history_view',
page: page,
size: size,
locale: locale
locale: locale,
sort_direction: sortDirection,
sort_by: sortBy
}
}),
headers: {