From d4b699500a0b30179d7c5c1ec128e2312df92270 Mon Sep 17 00:00:00 2001 From: Mariana Date: Fri, 22 Mar 2024 09:50:50 -0300 Subject: [PATCH 1/3] feat: Add new page flow trigger --- src/components/BarChart.vue | 104 ++++++ src/mocks/barChartData.json | 15 + src/mocks/dashboards.json | 3 +- src/router/index.js | 6 + .../dashboards/Dashboard/FlowTrigger.vue | 327 ++++++++++++++++++ src/views/dashboards/Home/index.vue | 19 +- 6 files changed, 467 insertions(+), 7 deletions(-) create mode 100644 src/components/BarChart.vue create mode 100644 src/mocks/barChartData.json create mode 100644 src/views/dashboards/Dashboard/FlowTrigger.vue diff --git a/src/components/BarChart.vue b/src/components/BarChart.vue new file mode 100644 index 00000000..33f43961 --- /dev/null +++ b/src/components/BarChart.vue @@ -0,0 +1,104 @@ + + + diff --git a/src/mocks/barChartData.json b/src/mocks/barChartData.json new file mode 100644 index 00000000..13e1d3e4 --- /dev/null +++ b/src/mocks/barChartData.json @@ -0,0 +1,15 @@ +{ + "categories": [ + "Fluxo principal", + "Pós compra", + "Recuperar carrinho", + "Busca de produtos", + "Fechamento de pedidos", + "Disparo fornecedores", + "[Zero shot] Classificação", + "Ofertas", + "Carrinho abandonado", + "Pesquisa satisfação" + ], + "data": ["759", "623", "589", "511", "416", "387", "234", "215", "189", "146"] +} \ No newline at end of file diff --git a/src/mocks/dashboards.json b/src/mocks/dashboards.json index 7f0bd82e..d594751f 100644 --- a/src/mocks/dashboards.json +++ b/src/mocks/dashboards.json @@ -1,5 +1,4 @@ [ { "id": 1, "title": "Atendimento humano" }, - { "id": 2, "title": "Chatbot" }, - { "id": 3, "title": "Disparo de fluxos" } + { "id": 2, "title": "Chatbot" } ] diff --git a/src/router/index.js b/src/router/index.js index 49b03d4e..ecb5c01c 100644 --- a/src/router/index.js +++ b/src/router/index.js @@ -2,6 +2,7 @@ import { createRouter, createWebHistory } from 'vue-router'; import Home from '@/views/insights/Home/index.vue'; import Dashboards from '@/views/dashboards/Home/index.vue'; import Dashboard from '@/views/dashboards/Dashboard/index.vue'; +import FlowTrigger from '@/views/dashboards/Dashboard/FlowTrigger.vue'; const router = createRouter({ history: createWebHistory(import.meta.env.BASE_URL), @@ -32,6 +33,11 @@ const router = createRouter({ cardId: route.params.cardId, }), }, + { + path: '/dashboards/flow-trigger', + name: 'flow', + component: FlowTrigger, + }, ], }); diff --git a/src/views/dashboards/Dashboard/FlowTrigger.vue b/src/views/dashboards/Dashboard/FlowTrigger.vue new file mode 100644 index 00000000..494f350d --- /dev/null +++ b/src/views/dashboards/Dashboard/FlowTrigger.vue @@ -0,0 +1,327 @@ + + + + + diff --git a/src/views/dashboards/Home/index.vue b/src/views/dashboards/Home/index.vue index 97a91626..8c8f81fc 100644 --- a/src/views/dashboards/Home/index.vue +++ b/src/views/dashboards/Home/index.vue @@ -1,9 +1,12 @@ From ac262bb0a71ce31a3930c3babca97aadefc17195 Mon Sep 17 00:00:00 2001 From: Mariana Date: Fri, 22 Mar 2024 10:52:21 -0300 Subject: [PATCH 2/3] fix: Add eslint disable for apexchart --- src/components/BarChart.vue | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/components/BarChart.vue b/src/components/BarChart.vue index 33f43961..62218cc5 100644 --- a/src/components/BarChart.vue +++ b/src/components/BarChart.vue @@ -1,5 +1,6 @@ +