mirror of
https://github.com/rjNemo/ticket_manager
synced 2026-06-12 11:46:40 +00:00
[UI] Users Modal done
This commit is contained in:
parent
d80225786f
commit
f043ac76ba
2 changed files with 26 additions and 20 deletions
|
|
@ -47,7 +47,12 @@ export const Modal: FC<IProps> = ({
|
||||||
const classes = useStyles();
|
const classes = useStyles();
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<Dialog open={show} onClose={handleClose} maxWidth="md" fullWidth>
|
<Dialog
|
||||||
|
open={show}
|
||||||
|
onClose={handleClose}
|
||||||
|
maxWidth="md"
|
||||||
|
// fullWidth
|
||||||
|
>
|
||||||
<DialogTitle disableTypography className={classes.root}>
|
<DialogTitle disableTypography className={classes.root}>
|
||||||
<Typography variant="h6">{name}</Typography>
|
<Typography variant="h6">{name}</Typography>
|
||||||
{handleClose ? (
|
{handleClose ? (
|
||||||
|
|
|
||||||
|
|
@ -90,25 +90,26 @@ export const UsersModal: FC<IProps> = ({
|
||||||
handleChange={handleChange}
|
handleChange={handleChange}
|
||||||
/>
|
/>
|
||||||
</Grid>
|
</Grid>
|
||||||
|
<Grid container justify="center">
|
||||||
<List dense className={classes.root}>
|
<List dense className={classes.root}>
|
||||||
{allUsers.map((u: User) => (
|
{allUsers.map((u: User) => (
|
||||||
<ListItem key={u.id}>
|
<ListItem key={u.id}>
|
||||||
<ListItemAvatar>
|
<ListItemAvatar>
|
||||||
<Avatar alt={u.fullName} src={u.picture} />
|
<Avatar alt={u.fullName} src={u.picture} />
|
||||||
</ListItemAvatar>
|
</ListItemAvatar>
|
||||||
<ListItemText id={u.id} primary={u.fullName} />
|
<ListItemText id={u.id} primary={u.fullName} />
|
||||||
<ListItemSecondaryAction>
|
<ListItemSecondaryAction>
|
||||||
<Checkbox
|
<Checkbox
|
||||||
edge="end"
|
edge="end"
|
||||||
onChange={handleToggle(u.id)}
|
onChange={handleToggle(u.id)}
|
||||||
checked={members.indexOf(u.id) !== -1}
|
checked={members.indexOf(u.id) !== -1}
|
||||||
inputProps={{ "aria-labelledby": `checkbox-${u.id}` }}
|
inputProps={{ "aria-labelledby": `checkbox-${u.id}` }}
|
||||||
/>
|
/>
|
||||||
</ListItemSecondaryAction>
|
</ListItemSecondaryAction>
|
||||||
</ListItem>
|
</ListItem>
|
||||||
))}
|
))}
|
||||||
</List>
|
</List>
|
||||||
|
</Grid>
|
||||||
</Modal>
|
</Modal>
|
||||||
);
|
);
|
||||||
};
|
};
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue