disable save when there are no changes (#975)

fixes: #679
This commit is contained in:
Erik Jan de Wit 2021-08-10 12:15:23 +02:00 committed by GitHub
parent d15da05d54
commit 9aa1cd0286
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 4 additions and 6 deletions

View file

@ -177,11 +177,7 @@ export const AttributesForm = ({
</Tbody>
</TableComposable>
<ActionGroup className="kc-attributes__action-group">
<Button
variant="primary"
type="submit"
isDisabled={!formState.isDirty}
>
<Button variant="primary" type="submit" isDisabled={!watchLast}>
{t("common:save")}
</Button>
<Button

View file

@ -47,7 +47,9 @@ export const GroupTable = () => {
const loader = async () => {
const groupsData = id
? (await adminClient.groups.findOne({ id })).subGroups
: await adminClient.groups.find();
: await adminClient.groups.find({
briefRepresentation: false,
} as unknown as any);
if (!groupsData) {
history.push(`/${realm}/groups`);