Skip to content

Commit

Permalink
UPDATE: frontend corregido
Browse files Browse the repository at this point in the history
  • Loading branch information
Alejandro-MOP committed Aug 8, 2022
1 parent 5457bcb commit 66c044d
Show file tree
Hide file tree
Showing 3 changed files with 212 additions and 196 deletions.
164 changes: 82 additions & 82 deletions frontend/src/views/admin/LogBook.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,99 +5,99 @@ import MenuItem from '@mui/material/MenuItem';
import FormControl from '@mui/material/FormControl';
import Select, { SelectChangeEvent } from '@mui/material/Select';
import {
Button,
Input,
InputAdornment,
Table,
TableBody,
TableCell,
TableContainer,
TableHead,
TableRow,
TextField,
Button,
Input,
InputAdornment,
Table,
TableBody,
TableCell,
TableContainer,
TableHead,
TableRow,
TextField,
} from '@mui/material';
import { Box } from '@mui/system';
import Paper from '@mui/material/Paper';

function createData(name, equipo, origenDestino, fecha) {
return { name, equipo, origenDestino, fecha };
return { name, equipo, origenDestino, fecha };
}

const rows = [
createData('Frozen yoghurt', 159, 6.0, 24, 4.0),
createData('Ice cream sandwich', 237, 9.0, 37, 4.3),
createData('Eclair', 262, 16.0, 24, 6.0),
createData('Cupcake', 305, 3.7, 67, 4.3),
createData('Gingerbread', 356, 16.0, 49, 3.9),
createData('13:00', 'Juan carlos', 'mackBook', 'Niza'),
createData('13:00', 'Juan carlos', 'mackBook', 'Niza'),
];

export const LogBook = () => {
const [age, setAge] = React.useState('');
const [age, setAge] = React.useState('');

return (
<div>
<h2 className='text-center mb-5'>Bitacora de Registros</h2>
<Box
component='form'
sx={{
'& > :not(style)': { m: 1, width: '25ch', marginBottom: '4rem' },
}}
noValidate
autoComplete='off'>
<FormControl>
<InputLabel htmlFor='age-simple'>Plantel</InputLabel>
<Select
// value={age}
// onChange={(e: SelectChangeEvent) => setAge(e.target.value)}
input={<Input name='age' id='age-simple' />}>
<MenuItem value=' '>
<em>None</em>
</MenuItem>
<MenuItem value={10}>Niza</MenuItem>
<MenuItem value={20}>Hr</MenuItem>
<MenuItem value={30}>Londres</MenuItem>
</Select>
</FormControl>
<TextField
id='date'
label='Fecha'
type='date'
defaultValue='2017-05-24'
InputLabelProps={{
shrink: true,
}}
/>
<Button variant='contained' color='primary'>
Buscar
</Button>
</Box>
return (
<div>
<h2 className='text-center mb-5'>Bitacora de Registros</h2>
<Box
component='form'
sx={{
'& > :not(style)': { m: 1, width: '25ch', marginBottom: '4rem' },
}}
noValidate
autoComplete='off'
>
<FormControl>
<InputLabel htmlFor='age-simple'>Plantel</InputLabel>
<Select
// value={age}
// onChange={(e: SelectChangeEvent) => setAge(e.target.value)}
input={<Input name='age' id='age-simple' />}
>
<MenuItem value=' '>
<em>None</em>
</MenuItem>
<MenuItem value={10}>Niza</MenuItem>
<MenuItem value={20}>Hr</MenuItem>
<MenuItem value={30}>Londres</MenuItem>
</Select>
</FormControl>
<TextField
id='date'
label='Fecha'
type='date'
defaultValue='2017-05-24'
InputLabelProps={{
shrink: true,
}}
/>
<Button variant='contained' color='primary'>
Buscar
</Button>
</Box>

<TableContainer component={Paper}>
<Table sx={{ minWidth: 650 }} aria-label='simple table'>
<TableHead>
<TableRow>
<TableCell>Dessert (100g serving)</TableCell>
<TableCell align='right'>Calories</TableCell>
<TableCell align='right'>Fat&nbsp;(g)</TableCell>
<TableCell align='right'>Carbs&nbsp;(g)</TableCell>
<TableCell align='right'>Protein&nbsp;(g)</TableCell>
</TableRow>
</TableHead>
<TableBody>
{rows.map((row) => (
<TableRow key={row.name} sx={{ '&:last-child td, &:last-child th': { border: 0 } }}>
<TableCell component='th' scope='row'>
{row.name}
</TableCell>
<TableCell align='right'>{row.calories}</TableCell>
<TableCell align='right'>{row.fat}</TableCell>
<TableCell align='right'>{row.carbs}</TableCell>
<TableCell align='right'>{row.protein}</TableCell>
</TableRow>
))}
</TableBody>
</Table>
</TableContainer>
</div>
);
<TableContainer component={Paper}>
<Table sx={{ minWidth: 650 }} aria-label='simple table'>
<TableHead>
<TableRow>
<TableCell>Hora</TableCell>
<TableCell align='center'>Nombre del Docente</TableCell>
<TableCell align='center'>Dispositivo</TableCell>
<TableCell align='center'>Plantel</TableCell>
</TableRow>
</TableHead>
<TableBody>
{rows.map(row => (
<TableRow
key={row.name}
sx={{ '&:last-child td, &:last-child th': { border: 0 } }}
>
<TableCell component='th' scope='row'>
{row.name}
</TableCell>
<TableCell align='center'>{row.equipo}</TableCell>
<TableCell align='center'>{row.origenDestino}</TableCell>
<TableCell align='center'>{row.fecha}</TableCell>
</TableRow>
))}
</TableBody>
</Table>
</TableContainer>
</div>
);
};
127 changes: 58 additions & 69 deletions frontend/src/views/admin/Notifications.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,75 +6,64 @@ import ListItemText from '@mui/material/ListItemText';
import ListItemAvatar from '@mui/material/ListItemAvatar';
import Avatar from '@mui/material/Avatar';
import Typography from '@mui/material/Typography';
import Button from '@mui/material/Button';

export const Notifications = () => {
return (
<>
<h2 className='text-center mb-5'>Notificaciones</h2>
<List sx={{ width: '100%', maxWidth: 360, bgcolor: 'background.paper' }}>
<ListItem alignItems='flex-start'>
<ListItemAvatar>
<Avatar alt='Remy Sharp' src='/static/images/avatar/1.jpg' />
</ListItemAvatar>
<ListItemText
primary='Brunch this weekend?'
secondary={
<React.Fragment>
<Typography
sx={{ display: 'inline' }}
component='span'
variant='body2'
color='text.primary'>
Ali Connors
</Typography>
{" — I'll be in your neighborhood doing errands this…"}
</React.Fragment>
}
/>
</ListItem>
<Divider variant='inset' component='li' />
<ListItem alignItems='flex-start'>
<ListItemAvatar>
<Avatar alt='Travis Howard' src='/static/images/avatar/2.jpg' />
</ListItemAvatar>
<ListItemText
primary='Summer BBQ'
secondary={
<React.Fragment>
<Typography
sx={{ display: 'inline' }}
component='span'
variant='body2'
color='text.primary'>
to Scott, Alex, Jennifer
</Typography>
{" — Wish I could come, but I'm out of town this…"}
</React.Fragment>
}
/>
</ListItem>
<Divider variant='inset' component='li' />
<ListItem alignItems='flex-start'>
<ListItemAvatar>
<Avatar alt='Cindy Baker' src='/static/images/avatar/3.jpg' />
</ListItemAvatar>
<ListItemText
primary='Oui Oui'
secondary={
<React.Fragment>
<Typography
sx={{ display: 'inline' }}
component='span'
variant='body2'
color='text.primary'>
Sandra Adams
</Typography>
{' — Do you have Paris recommendations? Have you ever…'}
</React.Fragment>
}
/>
</ListItem>
</List>
</>
);
return (
<>
<h2 className='text-center mb-5'>Notificaciones</h2>
<List sx={{ width: '100%', maxWidth: 360, bgcolor: 'background.paper' }}>
<ListItem alignItems='flex-start'>
<ListItemAvatar>
<Avatar alt='Aemy Sharp' src='/static/images/avatar/1.jpg' />
</ListItemAvatar>
<ListItemText
primary='Alex Montes de Oca'
secondary={<React.Fragment>{'ha perdiddo su dispositivo'}</React.Fragment>}
/>
<Button
variant='contained'
color='primary'
sx={{ marginLeft: 'auto', witdh: '50%', height: '50px' }}
>
Ver mas detalles
</Button>
</ListItem>
<Divider variant='inset' component='li' />
<ListItem alignItems='flex-start'>
<ListItemAvatar>
<Avatar alt='Aemy Sharp' src='/static/images/avatar/1.jpg' />
</ListItemAvatar>
<ListItemText
primary='Alex Montes de Oca'
secondary={<React.Fragment>{'ha perdiddo su dispositivo'}</React.Fragment>}
/>
<Button
variant='contained'
color='primary'
sx={{ marginLeft: 'auto', witdh: '50%', height: '50px' }}
>
Ver mas detalles
</Button>
</ListItem>
<Divider variant='inset' component='li' />
<ListItem alignItems='flex-start'>
<ListItemAvatar>
<Avatar alt='Aemy Sharp' src='/static/images/avatar/1.jpg' />
</ListItemAvatar>
<ListItemText
primary='Alex Montes de Oca'
secondary={<React.Fragment>{'ha perdiddo su dispositivo'}</React.Fragment>}
/>
<Button
variant='contained'
color='primary'
sx={{ marginLeft: 'auto', witdh: '50%', height: '50px' }}
>
Ver mas detalles
</Button>
</ListItem>
</List>
</>
);
};
Loading

0 comments on commit 66c044d

Please sign in to comment.