Skip to content

Commit

Permalink
feat: Ajout d'un lien Teams à la fiche d'un employé.
Browse files Browse the repository at this point in the history
  • Loading branch information
remillc committed Aug 28, 2024
1 parent a22b879 commit 027e83e
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions src/components/personnel/FichePersonnel.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -102,12 +102,13 @@ export default function ListePersonnel() {
return option.discipline === value.discipline
}}
renderInput={(params) => <TextField {...params} label="Cherchez une discipline..." fullWidth sx={{ mb: 2 }} />}
renderOption={(props, { nomComplet, discipline, thumb } = option) => {
renderOption={(props, { nomComplet, discipline, thumb, ...rest } = option) => {
console.log('rest: ', rest)
return (
<li {...props}>
<Grid container gap={2} alignItems="center" flexWrap="nowrap">
<Grid item sx={{ display: 'flex' }}>
<GatsbyImage image={thumb} alt={nomComplet} />
<GatsbyImage image={getImage(thumb)} alt={nomComplet} />
</Grid>
<Grid item sx={{ wordWrap: 'break-word' }}>
<Typography variant="body">{nomComplet}</Typography>
Expand Down Expand Up @@ -161,8 +162,8 @@ export default function ListePersonnel() {
</CardContent>
<CardActions sx={{ justifyContent: 'flex-end' }}>
<Button>Action secondaire</Button>
<Button variant="contained" disableElevation>
Écrivez-moi!
<Button variant="contained" disableElevation href={`https://teams.microsoft.com/l/chat/0/0?users=${value.courriel}`} target="_blank" rel="noopener noreferrer">
Textez-moi!
</Button>
</CardActions>
</Card>
Expand Down

0 comments on commit 027e83e

Please sign in to comment.