Move Toolbar's alwaysEnableSaveButton into SaveButton

https: //marmelab.com/react-admin/Upgrade.html#toolbars-alwaysenablesavebutton-prop-has-been-removed

Change-Id: I6c8693d4f55bfabdeaa677bd294d8663b7f14d69
This commit is contained in:
dklimpel 2024-02-05 22:14:54 +01:00 committed by Manuel Stahl
parent 82578c6570
commit 2c769c309e

View file

@ -12,6 +12,7 @@ import {
NumberField,
NumberInput,
regex,
SaveButton,
SimpleForm,
TextInput,
TextField,
@ -80,7 +81,15 @@ export const RegistrationTokenList = props => (
export const RegistrationTokenCreate = props => (
<Create {...props}>
<SimpleForm redirect="list" toolbar={<Toolbar alwaysEnableSaveButton />}>
<SimpleForm
redirect="list"
toolbar={
<Toolbar>
{/* It is possible to create tokens per default without input. */}
<SaveButton alwaysEnable />
</Toolbar>
}
>
<TextInput
source="token"
autoComplete="off"