mirror of
https://github.com/UA-Fediland/synapse-admin.git
synced 2024-12-23 13:33:18 +00:00
Add 3pids to user (#24)
This commit is contained in:
parent
fccf23c64c
commit
dfc643a10f
3 changed files with 39 additions and 0 deletions
|
@ -1,11 +1,13 @@
|
|||
import React from "react";
|
||||
import {
|
||||
ArrayInput,
|
||||
Datagrid,
|
||||
Create,
|
||||
Edit,
|
||||
List,
|
||||
Filter,
|
||||
SimpleForm,
|
||||
SimpleFormIterator,
|
||||
BooleanField,
|
||||
BooleanInput,
|
||||
ImageField,
|
||||
|
@ -13,6 +15,7 @@ import {
|
|||
TextField,
|
||||
TextInput,
|
||||
ReferenceField,
|
||||
SelectInput,
|
||||
regex,
|
||||
} from "react-admin";
|
||||
|
||||
|
@ -73,6 +76,18 @@ export const UserCreate = props => (
|
|||
<TextInput source="displayname" />
|
||||
<PasswordInput source="password" autoComplete="new-password" />
|
||||
<BooleanInput source="admin" />
|
||||
<ArrayInput source="threepids">
|
||||
<SimpleFormIterator>
|
||||
<SelectInput
|
||||
source="medium"
|
||||
choices={[
|
||||
{ id: "email", name: "resources.users.email" },
|
||||
{ id: "msisdn", name: "resources.users.msisdn" },
|
||||
]}
|
||||
/>
|
||||
<TextInput source="address" />
|
||||
</SimpleFormIterator>
|
||||
</ArrayInput>
|
||||
</SimpleForm>
|
||||
</Create>
|
||||
);
|
||||
|
@ -85,6 +100,18 @@ export const UserEdit = props => (
|
|||
<PasswordInput source="password" autoComplete="new-password" />
|
||||
<BooleanInput source="admin" />
|
||||
<BooleanInput source="deactivated" />
|
||||
<ArrayInput source="threepids">
|
||||
<SimpleFormIterator>
|
||||
<SelectInput
|
||||
source="medium"
|
||||
choices={[
|
||||
{ id: "email", name: "resources.users.email" },
|
||||
{ id: "msisdn", name: "resources.users.msisdn" },
|
||||
]}
|
||||
/>
|
||||
<TextInput source="address" />
|
||||
</SimpleFormIterator>
|
||||
</ArrayInput>
|
||||
</SimpleForm>
|
||||
</Edit>
|
||||
);
|
||||
|
|
|
@ -15,6 +15,8 @@ export default {
|
|||
resources: {
|
||||
users: {
|
||||
name: "Benutzer",
|
||||
email: "E-Mail",
|
||||
msisdn: "Telefon",
|
||||
fields: {
|
||||
avatar: "Avatar",
|
||||
id: "Benutzer-ID",
|
||||
|
@ -27,6 +29,10 @@ export default {
|
|||
user_id: "Suche Benutzer",
|
||||
displayname: "Anzeigename",
|
||||
password: "Passwort",
|
||||
avatar_url: "Avatar URL",
|
||||
medium: "Medium",
|
||||
threepids: "3PIDs",
|
||||
address: "Adresse",
|
||||
},
|
||||
},
|
||||
rooms: {
|
||||
|
|
|
@ -15,6 +15,8 @@ export default {
|
|||
resources: {
|
||||
users: {
|
||||
name: "User |||| Users",
|
||||
email: "Email",
|
||||
msisdn: "Phone",
|
||||
fields: {
|
||||
avatar: "Avatar",
|
||||
id: "User-ID",
|
||||
|
@ -27,6 +29,10 @@ export default {
|
|||
user_id: "Search user",
|
||||
displayname: "Displayname",
|
||||
password: "Password",
|
||||
avatar_url: "Avatar URL",
|
||||
medium: "Medium",
|
||||
threepids: "3PIDs",
|
||||
address: "Address",
|
||||
},
|
||||
},
|
||||
rooms: {
|
||||
|
|
Loading…
Reference in a new issue