aboutsummaryrefslogtreecommitdiff
path: root/modern/src/admin/UsersPage.js
diff options
context:
space:
mode:
authorDesmond Kyeremeh <elDekyfin@gmail.com>2021-07-01 14:21:08 +0000
committerDesmond Kyeremeh <elDekyfin@gmail.com>2021-07-01 14:21:08 +0000
commita154c692e08f340f3a81e024fb8e9f1d3a56cf52 (patch)
tree7df4cbf0cfcc697ffdae0d7e38ac1b47a3b4c33e /modern/src/admin/UsersPage.js
parente5b727e1bc85e6c38a15c8917aae57a70533da46 (diff)
downloadtrackermap-web-a154c692e08f340f3a81e024fb8e9f1d3a56cf52.tar.gz
trackermap-web-a154c692e08f340f3a81e024fb8e9f1d3a56cf52.tar.bz2
trackermap-web-a154c692e08f340f3a81e024fb8e9f1d3a56cf52.zip
Used OptionsLayout for admin pages
Diffstat (limited to 'modern/src/admin/UsersPage.js')
-rw-r--r--modern/src/admin/UsersPage.js26
1 files changed, 16 insertions, 10 deletions
diff --git a/modern/src/admin/UsersPage.js b/modern/src/admin/UsersPage.js
index 630bea43..aed675c9 100644
--- a/modern/src/admin/UsersPage.js
+++ b/modern/src/admin/UsersPage.js
@@ -6,12 +6,13 @@ import t from '../common/localization';
import { useEffectAsync } from '../reactHelper';
import EditCollectionView from '../EditCollectionView';
import { formatBoolean } from '../common/formatter';
+import OptionsLayout from '../settings/OptionsLayout';
const useStyles = makeStyles(theme => ({
columnAction: {
width: theme.spacing(1),
- padding: theme.spacing(0, 1),
- },
+ padding: theme.spacing(0, 1)
+ }
}));
const UsersView = ({ updateTimestamp, onMenuClick }) => {
@@ -39,10 +40,12 @@ const UsersView = ({ updateTimestamp, onMenuClick }) => {
</TableRow>
</TableHead>
<TableBody>
- {items.map((item) => (
+ {items.map(item => (
<TableRow key={item.id}>
<TableCell className={classes.columnAction} padding="none">
- <IconButton onClick={(event) => onMenuClick(event.currentTarget, item.id)}>
+ <IconButton
+ onClick={event => onMenuClick(event.currentTarget, item.id)}
+ >
<MoreVertIcon />
</IconButton>
</TableCell>
@@ -56,15 +59,18 @@ const UsersView = ({ updateTimestamp, onMenuClick }) => {
</Table>
</TableContainer>
);
-}
+};
const UsersPage = () => {
return (
- <>
- <MainToolbar />
- <EditCollectionView content={UsersView} editPath="/user" endpoint="users" />
- </>
+ <OptionsLayout>
+ <EditCollectionView
+ content={UsersView}
+ editPath="/user"
+ endpoint="users"
+ />
+ </OptionsLayout>
);
-}
+};
export default UsersPage;