Urgent upload

pull/20/head
Renato Di Giacomo 2022-08-10 10:29:09 -03:00
parent 658191d90f
commit 3bfcf56ad8
2 changed files with 27 additions and 7 deletions

View File

@ -86,8 +86,8 @@ const TableUser = ({ classes, usersOnlineInfo, logout }) => {
<TableRow className={classes.tableRowHead}> <TableRow className={classes.tableRowHead}>
<TableCell>Nome</TableCell> <TableCell>Nome</TableCell>
<TableCell>Em Atendimento/Finalizado(s)</TableCell> <TableCell>Em Atendimento/Finalizado(s)</TableCell>
<TableCell>Por Fila abertos</TableCell> <TableCell>abertos Por Fila</TableCell>
<TableCell>Por Fila Fechados</TableCell> <TableCell>Fechados Por Fila</TableCell>
<TableCell>Tempo Online</TableCell> <TableCell>Tempo Online</TableCell>
<TableCell>Ações</TableCell> <TableCell>Ações</TableCell>
</TableRow> </TableRow>
@ -137,10 +137,10 @@ const TableUser = ({ classes, usersOnlineInfo, logout }) => {
<TableCell> <TableCell>
<div style={{ display: "flex", alignItems: "center", gap: "12px" }}> <div style={{ display: "flex", alignItems: "center", gap: "12px" }}>
<Typography className={classes.tableCounterOpen}> <Typography className={classes.tableCounterOpen}>
{user.sumOpen ? user.sumOpen.count : 0} {user.sumOpen === undefined ? 0 : user.sumOpen}
</Typography> </Typography>
<Typography className={classes.tableCounterClosed}> <Typography className={classes.tableCounterClosed}>
{user.sumClosed ? user.sumClosed.count : 0} {user.sumClosed === undefined ? 0 : user.sumClosed.count}
</Typography> </Typography>
</div> </div>
</TableCell> </TableCell>
@ -154,8 +154,18 @@ const TableUser = ({ classes, usersOnlineInfo, logout }) => {
gap: "12px", gap: "12px",
}} }}
> >
<Typography
className={classes.tableQueues}
title="Sem Fila"
style={{ backgroundColor: "grey" }}
>
{user.openClosedOutQueue.countOpen === 0
? ""
: user.openClosedOutQueue.countOpen}
</Typography>
{!user.openClosedInQueue ? ( {!user.openClosedInQueue ? (
<Typography>Sem fila</Typography> <Typography>Nenhuma fila atribuida</Typography>
) : ( ) : (
user.openClosedInQueue.map((queue) => ( user.openClosedInQueue.map((queue) => (
<Typography <Typography
@ -188,8 +198,17 @@ const TableUser = ({ classes, usersOnlineInfo, logout }) => {
gap: "12px", gap: "12px",
}} }}
> >
<Typography
className={classes.tableQueues}
title="Sem Fila"
style={{ backgroundColor: "grey" }}
>
{user.openClosedOutQueue.countClosed === 0
? ""
: user.openClosedOutQueue.countClosed}
</Typography>
{!user.openClosedInQueue ? ( {!user.openClosedInQueue ? (
<Typography>Sem fila</Typography> <Typography>Nenhuma fila atribuida</Typography>
) : ( ) : (
user.openClosedInQueue.map((queue) => ( user.openClosedInQueue.map((queue) => (
<Typography <Typography

View File

@ -281,7 +281,7 @@ const Dashboard = () => {
return () => { return () => {
socket.disconnect(); socket.disconnect();
}; };
}, []); }, [ticketStatusChange]);
useEffect(() => { useEffect(() => {
if (ticketStatusChange === "") return console.log("foi"); if (ticketStatusChange === "") return console.log("foi");
@ -488,6 +488,7 @@ const Dashboard = () => {
usersOnlineInfo={usersOnlineInfo} usersOnlineInfo={usersOnlineInfo}
logout={handleLogouOnlineUser} logout={handleLogouOnlineUser}
/> />
</Grid> </Grid>
</Paper> </Paper>
</Grid> </Grid>