mirror of
https://github.com/UA-Fediland/synapse-admin.git
synced 2024-11-08 15:54:51 +00:00
Show displayname as title for user
Change-Id: I0ba8e2265e5b8e1fe392f56052e96e0243cd3eb6
This commit is contained in:
parent
d812cff5fc
commit
1e6e526e3c
1 changed files with 10 additions and 1 deletions
|
@ -135,8 +135,17 @@ export const UserCreate = props => (
|
||||||
</Create>
|
</Create>
|
||||||
);
|
);
|
||||||
|
|
||||||
|
const UserTitle = ({ record }) => {
|
||||||
|
const translate = useTranslate();
|
||||||
|
return (
|
||||||
|
<span>
|
||||||
|
{translate("resources.users.name")}{" "}
|
||||||
|
{record ? `"${record.displayname}"` : ""}
|
||||||
|
</span>
|
||||||
|
);
|
||||||
|
};
|
||||||
export const UserEdit = props => (
|
export const UserEdit = props => (
|
||||||
<Edit {...props}>
|
<Edit {...props} title={<UserTitle />}>
|
||||||
<TabbedForm toolbar={<UserEditToolbar />}>
|
<TabbedForm toolbar={<UserEditToolbar />}>
|
||||||
<FormTab label="resources.users.name" icon={<PersonPinIcon />}>
|
<FormTab label="resources.users.name" icon={<PersonPinIcon />}>
|
||||||
<TextInput source="id" disabled />
|
<TextInput source="id" disabled />
|
||||||
|
|
Loading…
Reference in a new issue