@nixweb/nixloc-ui 0.0.121 → 0.0.124
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 +2 -2
- package/docs/src/store/modulos/relatorio.drawio +2 -2
- package/package.json +77 -77
- package/public/styles/app.css +1 -1
- 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} +8 -8
- package/src/component/forms/{Cor.vue → Color.vue} +9 -9
- package/src/component/forms/DateTime.vue +55 -55
- package/src/component/forms/{BotaoDropdown.vue → Dropdown.vue} +58 -58
- 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/{Topo.vue → Header.vue} +5 -5
- 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 +15 -15
- package/src/component/layout/Wizard.vue +3 -3
- package/src/component/shared/{CodigoEditor.vue → CodeEditor.vue} +25 -25
- package/src/component/shared/Collapse.vue +131 -0
- package/src/component/shared/Confirmation.vue +80 -0
- package/src/component/shared/{DocumentoEditor.vue → DocumentEditor.vue} +10 -16
- package/src/component/shared/{DocumentoPreview.vue → DocumentPreview.vue} +2 -2
- package/src/component/shared/ExportExcel.vue +67 -0
- package/src/component/shared/{ExportarPDF.vue → ExportPDF.vue} +18 -18
- package/src/component/shared/HeaderPrint.vue +36 -0
- package/src/component/shared/HorizontalFilter.vue +59 -0
- package/src/component/shared/LegendaParametro.vue +22 -22
- package/src/component/shared/{Carregando.vue → Loading.vue} +16 -16
- package/src/component/shared/LoadingMoreButton.vue +23 -0
- package/src/component/shared/Messages.vue +83 -0
- package/src/component/shared/{Paginacao.vue → Pagination.vue} +12 -12
- package/src/component/shared/ProgressBar.vue +21 -0
- package/src/component/shared/{BotaoConsulta.vue → QueryButton.vue} +16 -16
- package/src/component/shared/SaveCancel.vue +56 -0
- package/src/component/shared/{Pesquisa.vue → Search.vue} +46 -46
- package/src/component/shared/Table.vue +243 -0
- package/src/component/shared/TableButton.vue +36 -0
- package/src/component/shared/{Registro.vue → TableTotalRecords.vue} +7 -7
- package/src/component/shared/{ResumoTabela.vue → TableTotalization.vue} +12 -8
- package/src/component/shared/Tip.vue +42 -0
- package/src/component/shared/Toast.vue +7 -7
- package/src/component/shared/{FiltroVertical.vue → VerticalFilter.vue} +24 -24
- package/src/component/shared/query-builder/AddRule.vue +187 -0
- package/src/component/shared/query-builder/ConvertToOdata.js +80 -0
- package/src/component/shared/query-builder/DynamicComponent.vue +107 -0
- package/src/component/shared/query-builder/Fields.vue +127 -0
- package/src/component/shared/query-builder/ListDynamicComponent.vue +42 -0
- package/src/component/shared/query-builder/QueryBuilder.vue +25 -120
- package/src/component/shared/query-builder/{Filtro.vue → Rules.vue} +13 -18
- package/src/component/shared/query-builder/SelectRule.vue +96 -0
- package/src/component/shared/query-builder/Tags.vue +14 -14
- package/src/component/shared/query-builder/{Rodape.vue → Totalization.vue} +10 -10
- package/src/component/template/AddEditReport.vue +106 -0
- package/src/component/template/ListViewWithHandlerData.vue +231 -0
- package/src/component/template/ViewTemplateConfiguration.vue +69 -0
- package/src/component/template/ViewTemplateDocumentView.vue +227 -0
- package/src/component/template/ViewTemplateReportList.vue +230 -0
- package/src/component/template/ViewTemplateReportPreview.vue +500 -0
- package/src/component/template/ViewTemplateWithSalveCancel.vue +32 -0
- package/src/component/template/ViewTemplateWithTable.vue +49 -0
- package/src/component/template/model/Report.js +6 -0
- package/src/component/value-objects/DadosContato.vue +34 -35
- package/src/component/value-objects/DadosPessoa.vue +58 -58
- package/src/component/value-objects/Endereco.vue +96 -97
- 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/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 -335
- 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/BotaoCarregarMais.vue +0 -23
- package/src/component/shared/CabecalhoImpressao.vue +0 -36
- package/src/component/shared/Confirmacao.vue +0 -80
- package/src/component/shared/Dica.vue +0 -42
- package/src/component/shared/EsconderMostrar.vue +0 -131
- package/src/component/shared/ExportarExcel.vue +0 -67
- package/src/component/shared/FiltroHorizontal.vue +0 -59
- package/src/component/shared/Mensagem.vue +0 -86
- package/src/component/shared/Progresso.vue +0 -21
- package/src/component/shared/SalvarCancelar.vue +0 -56
- package/src/component/shared/Tabela.vue +0 -275
- package/src/component/shared/TabelaBotao.vue +0 -36
- package/src/component/shared/query-builder/Campo.vue +0 -116
- package/src/component/shared/query-builder/ConverteParaOdata.js +0 -77
- 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 -187
- package/src/component/shared/query-builder/main.js +0 -81
- package/src/component/template/ModeloAdicionarModificarView.vue +0 -32
- package/src/component/template/ModeloDocumentoView.vue +0 -227
- package/src/component/template/ModeloLista.vue +0 -231
- package/src/component/template/ModeloRelatorioListaView.vue +0 -227
- package/src/component/template/ModeloRelatorioView.vue +0 -489
- package/src/component/template/ModeloSubView.vue +0 -69
- package/src/component/template/ModeloView.vue +0 -49
- package/src/component/template/Relatorio.js +0 -10
- package/src/component/template/RelatorioAdicionarModificar.vue +0 -106
- package/src/store/modulos/generic.js +0 -494
- package/src/store/modulos/relatorio.js +0 -204
- package/src/store/modulos/usuario.js +0 -38
- package/src/store/modulos/validation.js +0 -39
|
@@ -1,204 +0,0 @@
|
|
|
1
|
-
import ConverteParaOdata from "@nixweb/nixloc-ui/src/component/shared/query-builder/ConverteParaOdata.js";
|
|
2
|
-
|
|
3
|
-
export default {
|
|
4
|
-
namespaced: true,
|
|
5
|
-
state: {
|
|
6
|
-
relatorio: {
|
|
7
|
-
campo: [],
|
|
8
|
-
filtro: [],
|
|
9
|
-
},
|
|
10
|
-
campoSelecionado: [],
|
|
11
|
-
campoOrdenado: {},
|
|
12
|
-
filtroSelecionado: { children: [] },
|
|
13
|
-
opcoes: {
|
|
14
|
-
valorInicial: [],
|
|
15
|
-
opcoes: []
|
|
16
|
-
},
|
|
17
|
-
opcoesValorInicial: [],
|
|
18
|
-
consulta: [],
|
|
19
|
-
resumo: [],
|
|
20
|
-
tags: []
|
|
21
|
-
},
|
|
22
|
-
getters: {
|
|
23
|
-
cabecalhoTabela: (state) => {
|
|
24
|
-
let lista = [];
|
|
25
|
-
state.relatorio.campo.forEach(function (value) {
|
|
26
|
-
if (value.mostrar) lista.push(value);
|
|
27
|
-
});
|
|
28
|
-
return lista;
|
|
29
|
-
},
|
|
30
|
-
opcoes: (state) => {
|
|
31
|
-
// opcoesValorInicial é quando vem do relatório salvo
|
|
32
|
-
|
|
33
|
-
state.opcoes = {
|
|
34
|
-
valorInicial: [],
|
|
35
|
-
opcoes: []
|
|
36
|
-
};
|
|
37
|
-
|
|
38
|
-
var tamanhoValorInicial = state.opcoesValorInicial.length;
|
|
39
|
-
|
|
40
|
-
state.relatorio.campo.forEach(function (value) {
|
|
41
|
-
let opcoes = { text: value.titulo, value: value.campo };
|
|
42
|
-
state.opcoes.opcoes.push(opcoes);
|
|
43
|
-
|
|
44
|
-
if (value.mostrar && tamanhoValorInicial == 0)
|
|
45
|
-
state.opcoes.valorInicial.push(value.campo);
|
|
46
|
-
|
|
47
|
-
if (tamanhoValorInicial > 0)
|
|
48
|
-
state.opcoes.valorInicial = state.opcoesValorInicial;
|
|
49
|
-
|
|
50
|
-
});
|
|
51
|
-
|
|
52
|
-
// se não tiver salvo, reseta o filtro que estava armazenado
|
|
53
|
-
/* if (tamanhoValorInicial == 0)
|
|
54
|
-
state.filtroSelecionado.children = [];*/
|
|
55
|
-
|
|
56
|
-
return state.opcoes;
|
|
57
|
-
},
|
|
58
|
-
filtroObrigatorio: (state) => {
|
|
59
|
-
var filtroObrigatorio = state.relatorio.filtro.filter(x => x.obrigatorio == true);
|
|
60
|
-
return filtroObrigatorio;
|
|
61
|
-
},
|
|
62
|
-
filtroSelecionado: (state) => {
|
|
63
|
-
let filtro = { children: [] };
|
|
64
|
-
|
|
65
|
-
state.filtroSelecionado.children.forEach(function (value) {
|
|
66
|
-
if (value.query.value != null && value.query.value != "" && value.query.value != undefined)
|
|
67
|
-
filtro.children.push(value);
|
|
68
|
-
});
|
|
69
|
-
return filtro;
|
|
70
|
-
},
|
|
71
|
-
temCampoSelecionado: (state) => (campo, valor) => {
|
|
72
|
-
var existe = valor.find((value) => {
|
|
73
|
-
if (campo == value) return true;
|
|
74
|
-
});
|
|
75
|
-
return existe;
|
|
76
|
-
},
|
|
77
|
-
oDataOrderBy: (state) => {
|
|
78
|
-
let orderBy = `$orderby=${state.campoOrdenado.id} ${state.campoOrdenado.ordenar}`;
|
|
79
|
-
return orderBy;
|
|
80
|
-
},
|
|
81
|
-
oDataSelect: (state) => {
|
|
82
|
-
let consulta = "";
|
|
83
|
-
let seqConsulta = 0;
|
|
84
|
-
|
|
85
|
-
state.relatorio.campo.forEach(function (obj) {
|
|
86
|
-
if (obj.mostrar || obj.obrigatorioOData) {
|
|
87
|
-
if (seqConsulta == 0) consulta += `$select=${obj.campo}`;
|
|
88
|
-
if (seqConsulta > 0) consulta += `,${obj.campo}`;
|
|
89
|
-
seqConsulta++;
|
|
90
|
-
}
|
|
91
|
-
});
|
|
92
|
-
|
|
93
|
-
return consulta;
|
|
94
|
-
},
|
|
95
|
-
oDataFilter: (state) => {
|
|
96
|
-
let consulta = "";
|
|
97
|
-
let resumo = "";
|
|
98
|
-
let seqConsulta = 0;
|
|
99
|
-
let seqResumo = 0;
|
|
100
|
-
var tamanho = state.consulta.length;
|
|
101
|
-
|
|
102
|
-
state.consulta.forEach(function (valor) {
|
|
103
|
-
if (valor.tipo == "campo") {
|
|
104
|
-
if (seqConsulta == 0 && tamanho > 0) consulta += `$filter=${valor.filtro}`;
|
|
105
|
-
if (seqConsulta > 0 && tamanho > 0) consulta += ` and ${valor.filtro}`;
|
|
106
|
-
seqConsulta++;
|
|
107
|
-
} else {
|
|
108
|
-
if (seqResumo == 0 && tamanho > 0) resumo += `${valor.filtro}`;
|
|
109
|
-
if (seqResumo > 0 && tamanho > 0) resumo += `,${valor.filtro}`;
|
|
110
|
-
seqResumo++;
|
|
111
|
-
}
|
|
112
|
-
});
|
|
113
|
-
|
|
114
|
-
return { consulta, resumo };
|
|
115
|
-
},
|
|
116
|
-
tags: (state) => {
|
|
117
|
-
state.tags = [];
|
|
118
|
-
state.filtroSelecionado.children.forEach(function (value) {
|
|
119
|
-
let valor = "";
|
|
120
|
-
let type = value.query.type;
|
|
121
|
-
|
|
122
|
-
if (value.query.value) {
|
|
123
|
-
if (type == "custom-component" && value.query.label == "Período") {
|
|
124
|
-
valor = `${value.query.value[0]} - ${value.query.value[1]}`;
|
|
125
|
-
}
|
|
126
|
-
|
|
127
|
-
if (type == "custom-component" && value.query.operator == "escolher") {
|
|
128
|
-
valor = value.query.value.conteudo;
|
|
129
|
-
}
|
|
130
|
-
|
|
131
|
-
if (type == "text" || type == "numeric") {
|
|
132
|
-
valor = `${value.query.operator} "${value.query.value}"`;
|
|
133
|
-
}
|
|
134
|
-
|
|
135
|
-
if (type == "checkbox") {
|
|
136
|
-
value.query.choices.forEach(function (opcoes) {
|
|
137
|
-
value.query.value.forEach(function (value) {
|
|
138
|
-
if (opcoes.value == value) {
|
|
139
|
-
valor += `${opcoes.label},`;
|
|
140
|
-
}
|
|
141
|
-
});
|
|
142
|
-
});
|
|
143
|
-
}
|
|
144
|
-
|
|
145
|
-
let tag = { id: value.query.id, titulo: value.query.label, valor: valor };
|
|
146
|
-
if (value.query.value != null) state.tags.push(tag);
|
|
147
|
-
}
|
|
148
|
-
});
|
|
149
|
-
return state.tags;
|
|
150
|
-
}
|
|
151
|
-
},
|
|
152
|
-
mutations: {
|
|
153
|
-
insereRelatorio: (state, obj) => {
|
|
154
|
-
state.relatorio = obj;
|
|
155
|
-
},
|
|
156
|
-
atualizaCampoSelecionado: (state, value) => {
|
|
157
|
-
state.campoSelecionado = value;
|
|
158
|
-
},
|
|
159
|
-
atualizaOpcoesValorInicial: (state, value) => {
|
|
160
|
-
state.opcoesValorInicial = value;
|
|
161
|
-
},
|
|
162
|
-
atualizaFiltroSelecionado: (state, value) => {
|
|
163
|
-
state.filtroSelecionado = value;
|
|
164
|
-
},
|
|
165
|
-
atualizaCampoOrdenado: (state, value) => {
|
|
166
|
-
state.campoOrdenado = value;
|
|
167
|
-
},
|
|
168
|
-
removeFiltroSelecionado: (state, id) => {
|
|
169
|
-
var filtro = state.filtroSelecionado.children.filter((x) => {
|
|
170
|
-
return x.query.id != id;
|
|
171
|
-
});
|
|
172
|
-
state.filtroSelecionado.children = filtro;
|
|
173
|
-
},
|
|
174
|
-
atualizaConsultaFiltro: (state, filtro) => {
|
|
175
|
-
state.resumo = [];
|
|
176
|
-
state.consulta = [];
|
|
177
|
-
|
|
178
|
-
filtro.children.forEach(function (chave) {
|
|
179
|
-
let valor = chave.query.value;
|
|
180
|
-
|
|
181
|
-
if (chave.query.choices && chave.query.tipo == "resumo") {
|
|
182
|
-
chave.query.choices.forEach(function (value) {
|
|
183
|
-
let obj = {
|
|
184
|
-
titulo: value.como.titulo,
|
|
185
|
-
valor: value.como.valor,
|
|
186
|
-
classeCss: chave.query.classeCss,
|
|
187
|
-
tipo: value.como.tipo,
|
|
188
|
-
};
|
|
189
|
-
state.resumo.push(obj);
|
|
190
|
-
});
|
|
191
|
-
}
|
|
192
|
-
let converteParaOdata = new ConverteParaOdata();
|
|
193
|
-
let filtro = converteParaOdata.converteFiltro(chave.query);
|
|
194
|
-
|
|
195
|
-
if (valor != null && valor != undefined && valor != "") {
|
|
196
|
-
if (filtro != "") {
|
|
197
|
-
let obj = { filtro: filtro, tipo: chave.query.tipo };
|
|
198
|
-
state.consulta.push(obj);
|
|
199
|
-
}
|
|
200
|
-
}
|
|
201
|
-
});
|
|
202
|
-
}
|
|
203
|
-
},
|
|
204
|
-
}
|
|
@@ -1,38 +0,0 @@
|
|
|
1
|
-
export default {
|
|
2
|
-
namespaced: true,
|
|
3
|
-
state: {
|
|
4
|
-
usuarioLogado: {},
|
|
5
|
-
menu: {
|
|
6
|
-
itens: []
|
|
7
|
-
},
|
|
8
|
-
},
|
|
9
|
-
getters: {
|
|
10
|
-
temRegra: (state) => (nome) => {
|
|
11
|
-
var temRegra = state.usuarioLogado.usuario.regras.find(obj => {
|
|
12
|
-
return obj.nome === nome
|
|
13
|
-
})
|
|
14
|
-
if (temRegra == undefined) return false;
|
|
15
|
-
return true;
|
|
16
|
-
},
|
|
17
|
-
temModulo: (state) => (nome) => {
|
|
18
|
-
var temRegra = state.usuarioLogado.usuario.modulos.find(obj => {
|
|
19
|
-
return obj.nome === nome
|
|
20
|
-
})
|
|
21
|
-
if (temRegra == undefined) return false;
|
|
22
|
-
return true;
|
|
23
|
-
}
|
|
24
|
-
},
|
|
25
|
-
mutations: {
|
|
26
|
-
insereUsuarioLogado: (state, obj) => {
|
|
27
|
-
state.usuarioLogado = obj;
|
|
28
|
-
},
|
|
29
|
-
insereItemMenu: (state, itens) => {
|
|
30
|
-
itens.forEach(function (obj) {
|
|
31
|
-
state.menu.itens.push(obj);
|
|
32
|
-
});
|
|
33
|
-
},
|
|
34
|
-
removeItensMenu: (state) => {
|
|
35
|
-
state.menu.itens = [];
|
|
36
|
-
},
|
|
37
|
-
},
|
|
38
|
-
}
|
|
@@ -1,39 +0,0 @@
|
|
|
1
|
-
export default {
|
|
2
|
-
namespaced: true,
|
|
3
|
-
state: {
|
|
4
|
-
formSujo: false,
|
|
5
|
-
validacao: [],
|
|
6
|
-
reiniciaForm: {
|
|
7
|
-
nome: undefined,
|
|
8
|
-
dataHora: undefined
|
|
9
|
-
}
|
|
10
|
-
},
|
|
11
|
-
getters: {
|
|
12
|
-
formValido: (state) => (formNome) => {
|
|
13
|
-
var temNotificacao = state.validacao.find(obj => {
|
|
14
|
-
return obj.formNome === formNome
|
|
15
|
-
})
|
|
16
|
-
if (temNotificacao != undefined) return false;
|
|
17
|
-
return true;
|
|
18
|
-
}
|
|
19
|
-
},
|
|
20
|
-
mutations: {
|
|
21
|
-
insereValidacao: (state, obj) => {
|
|
22
|
-
state.validacao.push(obj);
|
|
23
|
-
},
|
|
24
|
-
removeValidacao: (state, obj) => {
|
|
25
|
-
let filtro = state.validacao.filter(v => v.chave != obj.chave);
|
|
26
|
-
state.validacao = filtro;
|
|
27
|
-
},
|
|
28
|
-
reiniciaValidacao: (state, formNome) => {
|
|
29
|
-
state.reiniciaForm.dataHora = new Date();
|
|
30
|
-
state.reiniciaForm.nome = formNome;
|
|
31
|
-
},
|
|
32
|
-
insereFormSujo: (state, formSujo) => {
|
|
33
|
-
state.formSujo = formSujo;
|
|
34
|
-
},
|
|
35
|
-
removeFormSujo: (state) => {
|
|
36
|
-
state.formSujo = false;
|
|
37
|
-
}
|
|
38
|
-
},
|
|
39
|
-
}
|