Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

UIBULKED-587 Only Users from the first page are displayed in "Users" dropdown on "Logs" page #656

Merged
merged 2 commits into from
Nov 27, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@

* [UIBULKED-566](https://folio-org.atlassian.net/browse/UIBULKED-566) Bulk edit form - options cleanup.
* [UIBULKED-580](https://folio-org.atlassian.net/browse/UIBULKED-580) Refactor of publish coordinator related logic.
* [UIBULKED-587](https://folio-org.atlassian.net/browse/UIBULKED-587) Only Users from the first page are displayed in "Users" dropdown on "Logs" page.

## [4.2.2](https://github.com/folio-org/ui-bulk-edit/tree/v4.2.2) (2024-11-15)

Expand Down
5 changes: 1 addition & 4 deletions src/hooks/api/useBulkOperationUsers.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import { omit } from 'lodash';

import { makeQueryBuilder } from '@folio/stripes-acq-components';
import noop from 'lodash/noop';
import { LOGS_FILTERS, PAGINATION_CONFIG as pagination } from '../../constants';
import { LOGS_FILTERS } from '../../constants';
import { useErrorMessages } from '../useErrorMessages';

export const BULK_OPERATION_USERS_KEY = 'BULK_OPERATION_USERS_KEY';
Expand All @@ -24,15 +24,12 @@ export const useBulkOperationUsers = (filters, options) => {

const searchParams = {
query: logsQuery,
limit: pagination.limit,
offset: pagination.offset,
};

const { data, isLoading } = useQuery({
queryKey: [namespaceKey, filters],
queryFn: () => ky.get('bulk-operations/list-users', { searchParams }).json(),
onError: showErrorMessage,
onSuccess: showErrorMessage,
...options,
});

Expand Down
Loading