Merge branch 'master' into increase_export

This commit is contained in:
Dirk Klimpel 2020-04-06 12:44:54 +02:00 committed by GitHub
commit f51c904aa1
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 21 additions and 3 deletions

View File

@ -1,8 +1,12 @@
import React from "react";
import { Datagrid, List, TextField } from "react-admin";
import { Datagrid, List, TextField, Pagination } from "react-admin";
const RoomPagination = props => (
<Pagination {...props} rowsPerPageOptions={[10, 25, 50, 100, 500, 1000]} />
);
export const RoomList = props => (
<List {...props}>
<List {...props} pagination={<RoomPagination />}>
<Datagrid>
<TextField source="room_id" />
<TextField source="name" />

View File

@ -23,6 +23,7 @@ import {
ReferenceField,
SelectInput,
regex,
Pagination,
CreateButton,
ExportButton,
TopToolbar,
@ -66,6 +67,9 @@ const ListActions = ({
maxResults={maxResults}
/>
</TopToolbar>
const UserPagination = props => (
<Pagination {...props} rowsPerPageOptions={[10, 25, 50, 100, 500, 1000]} />
);
const UserFilter = props => (
@ -86,6 +90,7 @@ export const UserList = props => (
filterDefaultValues={{ guests: true, deactivated: false }}
bulkActionButtons={false}
actions={<ListActions maxResults={10000} />}
pagination={<UserPagination />}
>
<Datagrid rowClick="edit">
<ReferenceField
@ -150,7 +155,10 @@ export const UserEdit = props => (
<TextInput source="displayname" />
<PasswordInput source="password" autoComplete="new-password" />
<BooleanInput source="admin" />
<BooleanInput source="deactivated" />
<BooleanInput
source="deactivated"
helperText="resources.users.helper.deactivate"
/>
<ArrayInput source="threepids">
<SimpleFormIterator>
<SelectInput

View File

@ -35,6 +35,9 @@ export default {
threepids: "3PIDs",
address: "Adresse",
},
helper: {
deactivate: "Deaktivierte Nutzer können nicht wieder aktiviert werden.",
},
},
rooms: {
name: "Raum |||| Räume",

View File

@ -35,6 +35,9 @@ export default {
threepids: "3PIDs",
address: "Address",
},
helper: {
deactivate: "Deactivated users cannot be reactivated",
},
},
rooms: {
name: "Room |||| Rooms",