Sort the IDPs in the admin console admin and organization tables by alias (#32999)
- prevent issues when ordering by guiOrder due to pagination of results Closes #32669 Signed-off-by: Stefan Guilhen <sguilhen@redhat.com>
This commit is contained in:
parent
d9de358a7f
commit
6503d202ac
2 changed files with 8 additions and 3 deletions
|
@ -135,7 +135,7 @@ export default function IdentityProvidersSection() {
|
|||
params.search = search;
|
||||
}
|
||||
const providers = await adminClient.identityProviders.find(params);
|
||||
return sortBy(providers, ["config.guiOrder", "alias"]);
|
||||
return sortBy(providers, "alias");
|
||||
};
|
||||
|
||||
const navigateToCreate = (providerId: string) =>
|
||||
|
|
|
@ -12,6 +12,7 @@ import {
|
|||
Switch,
|
||||
ToolbarItem,
|
||||
} from "@patternfly/react-core";
|
||||
import { sortBy } from "lodash-es";
|
||||
import { BellIcon } from "@patternfly/react-icons";
|
||||
import { useState } from "react";
|
||||
import { useTranslation } from "react-i18next";
|
||||
|
@ -89,8 +90,12 @@ export const IdentityProviders = () => {
|
|||
[],
|
||||
);
|
||||
|
||||
const loader = () =>
|
||||
adminClient.organizations.listIdentityProviders({ orgId: orgId! });
|
||||
const loader = async () => {
|
||||
const providers = await adminClient.organizations.listIdentityProviders({
|
||||
orgId: orgId!,
|
||||
});
|
||||
return sortBy(providers, "alias");
|
||||
};
|
||||
|
||||
const [toggleUnlinkDialog, UnlinkConfirm] = useConfirmDialog({
|
||||
titleKey: "identityProviderUnlink",
|
||||
|
|
Loading…
Reference in a new issue