Skip to content

Commit

Permalink
Merge pull request #1634 from fhlavac/sort
Browse files Browse the repository at this point in the history
Fix users sorting when adding them to a new group
  • Loading branch information
radekkaluzik authored Jul 15, 2024
2 parents d4b0aa9 + 6325bbb commit 81d1f66
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/smart-components/group/add-group/users-list.js
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@ const UsersList = ({ selectedUsers, setSelectedUsers, userLinks, usesMetaInURL,
rows={createRows(userLinks, users, intl, selectedUsers, true)}
sortBy={sortByState}
onSort={(e, index, direction) => {
const orderBy = `${direction === 'desc' ? '-' : ''}${columns[index].key}`;
const orderBy = `${direction === 'desc' ? '-' : ''}${columns[index - 1].key}`;
setSortByState({ index, direction });
fetchData({ ...pagination, filters, usesMetaInURL, orderBy });
}}
Expand Down

0 comments on commit 81d1f66

Please sign in to comment.