diff --git a/frontend/src/pages/Connections/index.js b/frontend/src/pages/Connections/index.js index 8766f3b..98bf43b 100644 --- a/frontend/src/pages/Connections/index.js +++ b/frontend/src/pages/Connections/index.js @@ -413,113 +413,8 @@ const Connections = () => { )} - /> - - /* - - {confirmModalInfo.message} - - - - - {i18n.t("connections.title")} - - - - - - - - - - {i18n.t("connections.table.name")} - - - {i18n.t("connections.table.status")} - - - {i18n.t("connections.table.session")} - - - {i18n.t("connections.table.lastUpdate")} - - - {i18n.t("connections.table.default")} - - - {i18n.t("connections.table.actions")} - - - - - {loading ? ( - - ) : ( - <> - {whatsApps?.length > 0 && - whatsApps.map(whatsApp => ( - - {whatsApp.name} - - {renderStatusToolTips(whatsApp)} - - - {renderActionButtons(whatsApp)} - - - {format(parseISO(whatsApp.updatedAt), "dd/MM/yy HH:mm")} - - - {whatsApp.isDefault && ( -
- -
- )} -
- - handleEditWhatsApp(whatsApp)} - > - - - - { - handleOpenConfirmationModal("delete", whatsApp.id); - }} - > - - - -
- ))} - - )} -
-
-
-
*/ + /> + ); }; diff --git a/frontend/src/pages/Dashboard/index.js b/frontend/src/pages/Dashboard/index.js index 7d11703..95b0455 100644 --- a/frontend/src/pages/Dashboard/index.js +++ b/frontend/src/pages/Dashboard/index.js @@ -14,6 +14,8 @@ import { i18n } from "../../translate/i18n"; import Chart from "./Chart" +import { Can } from "../../components/Can"; + const useStyles = makeStyles(theme => ({ container: { paddingTop: theme.spacing(4), @@ -63,54 +65,68 @@ const Dashboard = () => { return tickets.length; } - return ( -
- - - - - - {i18n.t("dashboard.messages.inAttendance.title")} - - - - {GetTickets("open", "true", "false")} - + return ( + + ( +
+ + + + + + {i18n.t("dashboard.messages.inAttendance.title")} + + + + {GetTickets("open", "true", "false")} + + + - - - - - - {i18n.t("dashboard.messages.waiting.title")} - - - - {GetTickets("pending", "true", "false")} - + + + + {i18n.t("dashboard.messages.waiting.title")} + + + + {GetTickets("pending", "true", "false")} + + + - - - - - - {i18n.t("dashboard.messages.closed.title")} - - - - {GetTickets("closed", "true", "false")} - + + + + {i18n.t("dashboard.messages.closed.title")} + + + + {GetTickets("closed", "true", "false")} + + + - - - - - - - - - -
+ + + + + +
+
+
+ )} + /> + + + + + + + /**/ ) } diff --git a/frontend/src/rules.js b/frontend/src/rules.js index 7746ac5..dbc21f7 100644 --- a/frontend/src/rules.js +++ b/frontend/src/rules.js @@ -13,6 +13,7 @@ const rules = { "contacts-page:deleteContact", "connections-view:show", + "dashboard-view:show", ], }, };