@nixweb/nixloc-ui 0.0.119 → 0.0.122
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/docs/src/component/template/ModeloRelatorioView.drawio +160 -0
- package/docs/src/store/modulos/relatorio.drawio +37 -0
- package/package.json +77 -75
- package/public/index.html +2 -4
- package/public/styles/app.css +1 -2
- package/src/component/forms/{Botao.vue → Button.vue} +53 -57
- package/src/component/forms/CheckboxGroup.vue +63 -0
- package/src/component/forms/{CheckboxUnico.vue → CheckboxSimple.vue} +6 -6
- package/src/component/forms/{Cor.vue → Color.vue} +9 -9
- package/src/component/forms/DateTime.vue +53 -53
- package/src/component/forms/{BotaoDropdown.vue → Dropdown.vue} +50 -50
- package/src/component/forms/EditorHtml.vue +123 -0
- package/src/component/forms/FileUpload.vue +189 -0
- package/src/component/forms/InputDecimal.vue +137 -0
- package/src/component/forms/InputNumber.vue +149 -0
- package/src/component/forms/InputPassword.vue +135 -0
- package/src/component/forms/InputText.vue +157 -0
- package/src/component/forms/Modal.vue +15 -15
- package/src/component/forms/RadioGroup.vue +50 -0
- package/src/component/forms/Select.vue +337 -0
- package/src/component/forms/SelectStatic.vue +120 -0
- package/src/component/forms/TextArea.vue +126 -0
- package/src/component/forms/Toggle.vue +13 -13
- package/src/component/layout/{Conta.vue → Account.vue} +28 -28
- package/src/component/layout/{Alerta.vue → Alert.vue} +22 -22
- package/src/component/layout/Badge.vue +23 -23
- package/src/component/layout/{BarraFixa.vue → FixedBar.vue} +16 -16
- package/src/component/layout/{CarregandoTelaInteira.vue → LoadingFullPage.vue} +3 -3
- package/src/component/layout/Menu.vue +66 -66
- package/src/component/layout/{Moldura.vue → Molded.vue} +4 -4
- package/src/component/layout/Panel.vue +142 -0
- package/src/component/layout/Popover.vue +1 -1
- package/src/component/layout/{BarraRolagem.vue → Scrollbar.vue} +9 -11
- package/src/component/layout/Tag.vue +9 -9
- package/src/component/layout/Topo.vue +1 -1
- package/src/component/layout/Wizard.vue +3 -3
- package/src/component/shared/BotaoCarregarMais.vue +9 -9
- package/src/component/shared/BotaoConsulta.vue +9 -9
- package/src/component/shared/CabecalhoImpressao.vue +6 -6
- package/src/component/shared/CodigoEditor.vue +16 -16
- package/src/component/shared/Confirmacao.vue +28 -28
- package/src/component/shared/Dica.vue +10 -10
- package/src/component/shared/DocumentoEditor.vue +3 -3
- package/src/component/shared/DocumentoPreview.vue +2 -2
- package/src/component/shared/EsconderMostrar.vue +26 -26
- package/src/component/shared/ExportarExcel.vue +14 -14
- package/src/component/shared/ExportarPDF.vue +10 -10
- package/src/component/shared/FiltroHorizontal.vue +19 -19
- package/src/component/shared/LegendaParametro.vue +17 -17
- package/src/component/shared/{Carregando.vue → Loading.vue} +11 -11
- package/src/component/shared/Messages.vue +83 -0
- package/src/component/shared/Paginacao.vue +10 -10
- package/src/component/shared/Progresso.vue +2 -2
- package/src/component/shared/Registro.vue +2 -2
- package/src/component/shared/ResumoTabela.vue +6 -6
- package/src/component/shared/SalvarCancelar.vue +26 -26
- package/src/component/shared/{Pesquisa.vue → Search.vue} +36 -36
- package/src/component/shared/Tabela.vue +49 -49
- package/src/component/shared/TabelaBotao.vue +13 -13
- package/src/component/shared/Toast.vue +7 -7
- package/src/component/shared/{FiltroVertical.vue → VerticalFilter.vue} +14 -14
- package/src/component/shared/construtor-consulta/AdicionaFiltro.vue +191 -0
- package/src/component/shared/construtor-consulta/Campo.vue +127 -0
- package/src/component/shared/construtor-consulta/ComponenteDinamico.vue +109 -0
- package/src/component/shared/construtor-consulta/ConstrutorConsulta.vue +70 -0
- package/src/component/shared/construtor-consulta/ConverteParaOdata.js +80 -0
- package/src/component/shared/construtor-consulta/EscolherFiltro.vue +96 -0
- package/src/component/shared/{query-builder → construtor-consulta}/Filtro.vue +11 -16
- package/src/component/shared/construtor-consulta/ListaComponenteDinamico.vue +41 -0
- package/src/component/shared/{query-builder → construtor-consulta}/Rodape.vue +9 -9
- package/src/component/shared/{query-builder → construtor-consulta}/Tags.vue +7 -7
- package/src/component/shared/{query-builder → construtor-consulta}/utilities.js +0 -0
- package/src/component/template/ModeloAdicionarModificarView.vue +11 -11
- package/src/component/template/ModeloDocumentoView.vue +79 -79
- package/src/component/template/ModeloLista.vue +66 -66
- package/src/component/template/ModeloRelatorioListaView.vue +71 -68
- package/src/component/template/ModeloRelatorioView.vue +218 -200
- package/src/component/template/ModeloSubView.vue +13 -13
- package/src/component/template/ModeloView.vue +17 -17
- package/src/component/template/Relatorio.js +1 -5
- package/src/component/template/RelatorioAdicionarModificar.vue +44 -44
- package/src/component/value-objects/DadosContato.vue +27 -27
- package/src/component/value-objects/DadosPessoa.js +1 -1
- package/src/component/value-objects/DadosPessoa.vue +52 -52
- package/src/component/value-objects/Endereco.js +1 -1
- package/src/component/value-objects/Endereco.vue +83 -83
- package/src/config/dicas.js +1 -1
- package/src/config/token.js +2 -2
- package/src/store/modules/generic.js +489 -0
- package/src/store/modules/report.js +246 -0
- package/src/store/modules/user.js +38 -0
- package/src/store/modules/validation.js +39 -0
- package/src/store/store.js +4 -4
- package/public/js/menu.js +0 -11
- package/public/styles/menu.css +0 -1399
- package/src/component/forms/ArquivoUpload.vue +0 -199
- package/src/component/forms/CheckboxMultiplo.vue +0 -63
- package/src/component/forms/Decimal.vue +0 -137
- package/src/component/forms/Escolher.vue +0 -324
- package/src/component/forms/EscolherEstatico.vue +0 -139
- package/src/component/forms/Numero.vue +0 -153
- package/src/component/forms/Opcoes.vue +0 -51
- package/src/component/forms/Senha.vue +0 -139
- package/src/component/forms/Texto.vue +0 -161
- package/src/component/forms/TextoArea.vue +0 -126
- package/src/component/forms/TextoEditor.vue +0 -123
- package/src/component/layout/Painel.vue +0 -142
- package/src/component/shared/Mensagem.vue +0 -86
- package/src/component/shared/query-builder/Campo.vue +0 -116
- package/src/component/shared/query-builder/ConverteParaOdata.js +0 -73
- package/src/component/shared/query-builder/QueryBuilder.vue +0 -164
- package/src/component/shared/query-builder/components/CustomSelect.vue +0 -115
- package/src/component/shared/query-builder/components/QueryBuilderChildren.vue +0 -46
- package/src/component/shared/query-builder/components/QueryBuilderGroup.vue +0 -151
- package/src/component/shared/query-builder/components/QueryBuilderRule.vue +0 -81
- package/src/component/shared/query-builder/layouts/Bootstrap/BootstrapGroup.vue +0 -120
- package/src/component/shared/query-builder/layouts/Bootstrap/BootstrapRule.vue +0 -171
- package/src/component/shared/query-builder/main.js +0 -81
- package/src/store/modulos/generic.js +0 -494
- package/src/store/modulos/relatorio.js +0 -201
- package/src/store/modulos/usuario.js +0 -38
- package/src/store/modulos/validation.js +0 -39
|
@@ -1,59 +1,59 @@
|
|
|
1
1
|
<template>
|
|
2
2
|
<div>
|
|
3
3
|
<Painel
|
|
4
|
-
:
|
|
5
|
-
:
|
|
6
|
-
:
|
|
7
|
-
:
|
|
8
|
-
:
|
|
4
|
+
:module="panel.module"
|
|
5
|
+
:title="panel.title"
|
|
6
|
+
:showVerticalFilter="panel.showVerticalFilter"
|
|
7
|
+
:showSearch="panel.showSearch"
|
|
8
|
+
:showButtons="panel.showButtons"
|
|
9
9
|
>
|
|
10
|
-
<div slot="
|
|
10
|
+
<div slot="content-main">
|
|
11
11
|
<b-row>
|
|
12
12
|
<b-col xs="12" sm="12" md="12" lg="6" xl="6" v-if="todos.salvo.length > 0">
|
|
13
|
-
<div><i class="fas fa-file-alt
|
|
13
|
+
<div><i class="fas fa-file-alt icon-salvo"></i></i> Personalizado</div>
|
|
14
14
|
<hr class="hr" />
|
|
15
|
-
<div class="div-
|
|
15
|
+
<div class="div-molded" v-for="report in todos.salvo">
|
|
16
16
|
<div>
|
|
17
|
-
<
|
|
17
|
+
<Molded :borderRadius="12">
|
|
18
18
|
<b-row>
|
|
19
19
|
<b-col sm="1">
|
|
20
|
-
<i class="fas fa-file-alt
|
|
20
|
+
<i class="fas fa-file-alt icon-report"></i>
|
|
21
21
|
</b-col>
|
|
22
|
-
<b-col sm="10" @click="
|
|
23
|
-
<div>{{
|
|
22
|
+
<b-col sm="10" @click="navegateTo(report)">
|
|
23
|
+
<div>{{ report.nome }}</div>
|
|
24
24
|
</b-col>
|
|
25
25
|
<b-col sm="1">
|
|
26
26
|
<Confirmacao
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
:
|
|
27
|
+
title="Deseja excluir?"
|
|
28
|
+
type="danger"
|
|
29
|
+
:data="report"
|
|
30
30
|
:confirmado="excluir"
|
|
31
31
|
>
|
|
32
32
|
<div class="text-right">
|
|
33
|
-
<i class="fas fa-times-circle
|
|
33
|
+
<i class="fas fa-times-circle icon-remover"></i>
|
|
34
34
|
</div>
|
|
35
35
|
</Confirmacao>
|
|
36
36
|
</b-col>
|
|
37
37
|
</b-row>
|
|
38
|
-
</
|
|
38
|
+
</Molded>
|
|
39
39
|
</div>
|
|
40
40
|
</div>
|
|
41
41
|
</b-col>
|
|
42
42
|
<b-col xs="12" sm="12" md="12" lg="6" xl="6">
|
|
43
43
|
<div><i class="fas fa-file-chart-line"></i> Padrão</div>
|
|
44
44
|
<hr class="hr" />
|
|
45
|
-
<div class="div-
|
|
45
|
+
<div class="div-molded" v-for="report in todos.padrao">
|
|
46
46
|
<div>
|
|
47
|
-
<
|
|
47
|
+
<Molded :borderRadius="12">
|
|
48
48
|
<b-row>
|
|
49
49
|
<b-col sm="1">
|
|
50
|
-
<i class="fas fa-file-alt
|
|
50
|
+
<i class="fas fa-file-alt icon-report"></i>
|
|
51
51
|
</b-col>
|
|
52
|
-
<b-col sm="11" @click="
|
|
53
|
-
<div class="
|
|
52
|
+
<b-col sm="11" @click="navegateTo(report)">
|
|
53
|
+
<div class="side-by-side">{{ report.nome }}</div>
|
|
54
54
|
</b-col>
|
|
55
55
|
</b-row>
|
|
56
|
-
</
|
|
56
|
+
</Molded>
|
|
57
57
|
</div>
|
|
58
58
|
</div>
|
|
59
59
|
</b-col>
|
|
@@ -65,77 +65,80 @@
|
|
|
65
65
|
|
|
66
66
|
<script>
|
|
67
67
|
import Painel from "@nixweb/nixloc-ui/src/component/layout/Painel.vue";
|
|
68
|
-
import
|
|
68
|
+
import Molded from "@nixweb/nixloc-ui/src/component/layout/Molded";
|
|
69
69
|
import Confirmacao from "@nixweb/nixloc-ui/src/component/shared/Confirmacao";
|
|
70
70
|
|
|
71
71
|
import { mapState, mapGetters, mapActions, mapMutations } from "vuex";
|
|
72
72
|
|
|
73
73
|
export default {
|
|
74
74
|
name: "ModeloRelatorioListaView",
|
|
75
|
-
components: { Painel,
|
|
75
|
+
components: { Painel, Molded, Confirmacao },
|
|
76
76
|
props: {
|
|
77
|
-
|
|
77
|
+
panel: Object,
|
|
78
78
|
relatorios: Object,
|
|
79
79
|
},
|
|
80
80
|
data() {
|
|
81
81
|
return {
|
|
82
|
-
todos: {},
|
|
83
|
-
urlObterTodos: "/api/v1/shared/
|
|
84
|
-
urlRemover: "/api/v1/shared/
|
|
82
|
+
todos: { salvo: [] },
|
|
83
|
+
urlObterTodos: "/api/v1/shared/report/obter-todos",
|
|
84
|
+
urlRemover: "/api/v1/shared/report/remover",
|
|
85
85
|
};
|
|
86
86
|
},
|
|
87
87
|
computed: {
|
|
88
|
-
...mapState("generic", ["
|
|
88
|
+
...mapState("generic", ["search", "buscouPesquisa", "limpouPesquisa"]),
|
|
89
89
|
},
|
|
90
90
|
mounted() {
|
|
91
|
-
this.
|
|
91
|
+
this.getAll();
|
|
92
92
|
this.todos = JSON.parse(JSON.stringify(this.relatorios)); // remove observable
|
|
93
93
|
},
|
|
94
94
|
methods: {
|
|
95
|
-
...mapMutations("generic", ["
|
|
96
|
-
...mapMutations("
|
|
95
|
+
...mapMutations("generic", ["removeLoading"]),
|
|
96
|
+
...mapMutations("report", [
|
|
97
97
|
"atualizaFiltroSelecionado",
|
|
98
98
|
"atualizaCampoOrdenado",
|
|
99
|
-
"
|
|
99
|
+
"updateOptionsInitValue",
|
|
100
|
+
"atualizaConsultaFiltro"
|
|
100
101
|
]),
|
|
101
102
|
...mapActions("generic", ["getApi", "deleteAllApi"]),
|
|
102
|
-
|
|
103
|
-
let obj = {
|
|
103
|
+
getAll() {
|
|
104
|
+
let obj = { module: this.panel.module };
|
|
104
105
|
let params = { url: this.urlObterTodos, obj: obj };
|
|
105
106
|
this.getApi(params).then((response) => {
|
|
106
107
|
this.todos.salvo = [];
|
|
107
108
|
let self = this;
|
|
108
|
-
response.
|
|
109
|
+
response.content.data.forEach((item) => {
|
|
109
110
|
const consulta = JSON.parse(item.consulta);
|
|
110
111
|
let obj = {
|
|
111
112
|
id: item.id,
|
|
112
113
|
nome: item.nome,
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
114
|
+
routeName: consulta.routeName,
|
|
115
|
+
filter: consulta.filter,
|
|
116
|
+
field: consulta.field,
|
|
116
117
|
ordenacao: consulta.ordenacao,
|
|
117
118
|
};
|
|
118
119
|
self.todos.salvo.push(obj);
|
|
119
120
|
});
|
|
120
|
-
this.
|
|
121
|
+
this.removeLoading(["panel"]);
|
|
121
122
|
});
|
|
122
123
|
},
|
|
123
|
-
|
|
124
|
-
if (
|
|
125
|
-
let filtroSelecionado = { logicalOperator: "all", children:
|
|
126
|
-
this.
|
|
127
|
-
this.atualizaCampoOrdenado(
|
|
124
|
+
navegateTo(report) {
|
|
125
|
+
if (report.filter) {
|
|
126
|
+
let filtroSelecionado = { logicalOperator: "all", children: report.filter };
|
|
127
|
+
this.updateOptionsInitValue(report.field);
|
|
128
|
+
this.atualizaCampoOrdenado(report.ordenacao);
|
|
128
129
|
this.atualizaFiltroSelecionado(filtroSelecionado);
|
|
130
|
+
this.atualizaConsultaFiltro(filtroSelecionado);
|
|
129
131
|
} else {
|
|
130
|
-
this.
|
|
132
|
+
this.updateOptionsInitValue([]);
|
|
131
133
|
}
|
|
132
134
|
this.$router.push({
|
|
133
|
-
name:
|
|
135
|
+
name: report.routeName,
|
|
136
|
+
params: { id: report.id, nome: report.nome },
|
|
134
137
|
});
|
|
135
138
|
},
|
|
136
|
-
excluir(
|
|
139
|
+
excluir(data) {
|
|
137
140
|
let selecionados = [];
|
|
138
|
-
selecionados.push(
|
|
141
|
+
selecionados.push(data.id);
|
|
139
142
|
|
|
140
143
|
let params = {
|
|
141
144
|
url: this.urlRemover,
|
|
@@ -143,7 +146,7 @@ export default {
|
|
|
143
146
|
};
|
|
144
147
|
|
|
145
148
|
this.deleteAllApi(params).then((reponse) => {
|
|
146
|
-
if (reponse.
|
|
149
|
+
if (reponse.success) this.getAll();
|
|
147
150
|
});
|
|
148
151
|
},
|
|
149
152
|
},
|
|
@@ -154,37 +157,37 @@ export default {
|
|
|
154
157
|
let self = this;
|
|
155
158
|
setTimeout(function () {
|
|
156
159
|
self.todos.padrao.forEach(function (item) {
|
|
157
|
-
if (self.
|
|
158
|
-
if (item.nome == self.
|
|
160
|
+
if (self.search.filter.content == "igual") {
|
|
161
|
+
if (item.nome == self.search.content) padrao.push(item);
|
|
159
162
|
}
|
|
160
163
|
|
|
161
|
-
if (self.
|
|
162
|
-
if (item.nome.includes(self.
|
|
164
|
+
if (self.search.filter.content == "contem") {
|
|
165
|
+
if (item.nome.includes(self.search.content)) padrao.push(item);
|
|
163
166
|
}
|
|
164
167
|
});
|
|
165
168
|
|
|
166
169
|
self.todos.salvo.forEach(function (item) {
|
|
167
|
-
if (self.
|
|
168
|
-
if (item.nome == self.
|
|
170
|
+
if (self.search.filter.content == "igual") {
|
|
171
|
+
if (item.nome == self.search.content) salvo.push(item);
|
|
169
172
|
}
|
|
170
173
|
|
|
171
|
-
if (self.
|
|
172
|
-
if (item.nome.includes(self.
|
|
174
|
+
if (self.search.filter.content == "contem") {
|
|
175
|
+
if (item.nome.includes(self.search.content)) salvo.push(item);
|
|
173
176
|
}
|
|
174
177
|
});
|
|
175
178
|
|
|
176
179
|
self.todos.salvo = salvo;
|
|
177
180
|
self.todos.padrao = padrao;
|
|
178
181
|
|
|
179
|
-
self.
|
|
182
|
+
self.removeLoading(["pesquisar", "limpar"]);
|
|
180
183
|
}, 300);
|
|
181
184
|
},
|
|
182
185
|
limpouPesquisa: function () {
|
|
183
186
|
let self = this;
|
|
184
187
|
setTimeout(function () {
|
|
185
188
|
self.todos = self.relatorios;
|
|
186
|
-
self.
|
|
187
|
-
self.
|
|
189
|
+
self.getAll();
|
|
190
|
+
self.removeLoading(["pesquisar", "limpar"]);
|
|
188
191
|
}, 300);
|
|
189
192
|
},
|
|
190
193
|
},
|
|
@@ -192,30 +195,30 @@ export default {
|
|
|
192
195
|
</script>
|
|
193
196
|
|
|
194
197
|
<style scoped>
|
|
195
|
-
.
|
|
198
|
+
.icon-salvo {
|
|
196
199
|
color: #94aa2a;
|
|
197
200
|
}
|
|
198
201
|
|
|
199
|
-
.
|
|
202
|
+
.icon-remover {
|
|
200
203
|
color: red;
|
|
201
204
|
}
|
|
202
205
|
|
|
203
|
-
.
|
|
206
|
+
.icon-report {
|
|
204
207
|
font-size: 25px;
|
|
205
208
|
opacity: 0.2;
|
|
206
209
|
color: #577696;
|
|
207
210
|
}
|
|
208
211
|
|
|
209
|
-
.div-
|
|
212
|
+
.div-molded {
|
|
210
213
|
margin-bottom: 10px;
|
|
211
214
|
cursor: pointer;
|
|
212
215
|
}
|
|
213
216
|
|
|
214
|
-
.div-
|
|
217
|
+
.div-molded:hover {
|
|
215
218
|
background-color: #fafafc;
|
|
216
219
|
}
|
|
217
220
|
|
|
218
|
-
.
|
|
221
|
+
.description {
|
|
219
222
|
font-size: 13.5px;
|
|
220
223
|
color: rgb(117, 117, 117);
|
|
221
224
|
}
|