@nixweb/nixloc-ui 0.0.127 → 0.0.128
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/package.json +79 -79
- package/src/App.vue +13 -13
- package/src/component/forms/Button.vue +170 -170
- package/src/component/forms/CheckboxGroup.vue +72 -66
- package/src/component/forms/CheckboxSimple.vue +46 -42
- package/src/component/forms/Color.vue +38 -38
- package/src/component/forms/DateTime.vue +167 -163
- package/src/component/forms/Dropdown.vue +218 -224
- package/src/component/forms/EditorHtml.vue +126 -126
- package/src/component/forms/FileUpload.vue +185 -185
- package/src/component/forms/ImageUpload.vue +12 -4
- package/src/component/forms/IncrementDecrement.vue +101 -0
- package/src/component/forms/InputDecimal.vue +142 -138
- package/src/component/forms/InputNumber.vue +154 -154
- package/src/component/forms/InputPassword.vue +135 -135
- package/src/component/forms/InputText.vue +162 -157
- package/src/component/forms/Modal.vue +65 -65
- package/src/component/forms/RadioGroup.vue +50 -50
- package/src/component/forms/Select.vue +349 -340
- package/src/component/forms/SelectStatic.vue +127 -127
- package/src/component/forms/Slider.vue +18 -18
- package/src/component/forms/TextArea.vue +126 -126
- package/src/component/layout/Alert.vue +92 -92
- package/src/component/layout/Badge.vue +103 -103
- package/src/component/layout/FixedBar.vue +100 -68
- package/src/component/layout/Header.vue +38 -35
- package/src/component/layout/LoadingFullPage.vue +27 -27
- package/src/component/layout/Menu.vue +210 -215
- package/src/component/layout/Molded.vue +28 -27
- package/src/component/layout/Panel.vue +140 -140
- package/src/component/layout/Popover.vue +126 -126
- package/src/component/layout/ScrollBar.vue +42 -42
- package/src/component/layout/Tab.vue +135 -0
- package/src/component/layout/Wizard.vue +211 -211
- package/src/component/rental/DisplayPeriodRent.vue +81 -0
- package/src/component/rental/DisplayTotalization.vue +47 -0
- package/src/component/shared/Collapse.vue +131 -131
- package/src/component/shared/DocumentPreview.vue +1 -1
- package/src/component/shared/DocumentPublic.vue +34 -0
- package/src/component/shared/ExportPDF.vue +116 -116
- package/src/component/shared/HeaderReport.vue +1 -1
- package/src/component/shared/HorizontalFilter.vue +59 -59
- package/src/component/shared/Loading.vue +107 -107
- package/src/component/shared/LoadingMoreButton.vue +23 -23
- package/src/component/shared/Messages.vue +81 -81
- package/src/component/shared/PDFViewer.vue +22 -22
- package/src/component/shared/Pagination.vue +52 -52
- package/src/component/shared/ProgressBar.vue +22 -22
- package/src/component/shared/QueryButton.vue +66 -66
- package/src/component/shared/{BodyReport.vue → Report.vue} +8 -7
- package/src/component/shared/SaveCancel.vue +6 -1
- package/src/component/shared/Search.vue +154 -154
- package/src/component/shared/SelectOption.vue +18 -9
- package/src/component/shared/Table.vue +163 -254
- package/src/component/shared/TableButton.vue +36 -36
- package/src/component/shared/TableDraggable.vue +127 -0
- package/src/component/shared/TableItem.vue +177 -0
- package/src/component/shared/TableTotalization.vue +47 -47
- package/src/component/shared/Tip.vue +42 -42
- package/src/component/shared/Toast.vue +54 -54
- package/src/component/shared/TotalizationReport.vue +59 -0
- package/src/component/shared/VerticalFilter.vue +97 -97
- package/src/component/shared/query-builder/AddRule.vue +181 -181
- package/src/component/shared/query-builder/ConvertToOdata.js +3 -9
- package/src/component/shared/query-builder/DynamicComponent.vue +5 -1
- package/src/component/shared/query-builder/DynamicComponentList.vue +73 -62
- package/src/component/shared/query-builder/QueryBuilder.vue +69 -69
- package/src/component/shared/query-builder/utilities.js +21 -21
- package/src/component/template/ListViewWithDataHandler.vue +260 -238
- package/src/component/template/ReportCreateUpdate.vue +9 -2
- package/src/component/template/ViewTemplateConfiguration.vue +64 -63
- package/src/component/template/ViewTemplateDocumentView.vue +1 -0
- package/src/component/template/ViewTemplateReportPreview.vue +56 -12
- package/src/component/template/ViewTemplateWithSalveCancel.vue +32 -32
- package/src/component/template/ViewTemplateWithTable.vue +56 -56
- package/src/component/value-objects/Contact.vue +7 -0
- package/src/component/value-objects/Person.vue +15 -0
- package/src/config/axios.js +9 -9
- package/src/config/dicas.js +14 -14
- package/src/config/router.js +13 -13
- package/src/config/token.js +14 -14
- package/src/main.js +23 -23
- package/src/store/modules/generic.js +512 -494
- package/src/store/modules/report.js +37 -19
- package/src/store/modules/user.js +3 -0
- package/src/store/modules/validation.js +38 -38
- package/src/store/store.js +13 -13
- package/src/component/shared/query-builder/Totalization.vue +0 -38
|
@@ -1,63 +1,64 @@
|
|
|
1
|
-
<template>
|
|
2
|
-
<div>
|
|
3
|
-
<div>
|
|
4
|
-
<slot name="content-buttons"></slot>
|
|
5
|
-
<
|
|
6
|
-
|
|
7
|
-
<
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
:
|
|
12
|
-
:
|
|
13
|
-
:
|
|
14
|
-
:
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
</
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
}
|
|
63
|
-
|
|
1
|
+
<template>
|
|
2
|
+
<div>
|
|
3
|
+
<div>
|
|
4
|
+
<slot name="content-buttons"></slot>
|
|
5
|
+
<br v-if="templateList.dragAndDrop" />
|
|
6
|
+
<div v-if="showSearch">
|
|
7
|
+
<Search />
|
|
8
|
+
<br />
|
|
9
|
+
</div>
|
|
10
|
+
<ListViewWithDataHandler
|
|
11
|
+
:templateList="templateList"
|
|
12
|
+
:propsParam="propsParam"
|
|
13
|
+
:showMolded="false"
|
|
14
|
+
:showHorizontalFilter="showHorizontalFilter"
|
|
15
|
+
:buttonRemove="buttonRemove"
|
|
16
|
+
>
|
|
17
|
+
<div slot="content-buttons-table-header">
|
|
18
|
+
<slot name="content-buttons-table-header"></slot>
|
|
19
|
+
</div>
|
|
20
|
+
<div slot="content-filter-horizontal">
|
|
21
|
+
<slot name="content-filter-horizontal"></slot>
|
|
22
|
+
</div>
|
|
23
|
+
<div slot="content-buttons-table">
|
|
24
|
+
<slot name="content-buttons-table"></slot>
|
|
25
|
+
</div>
|
|
26
|
+
</ListViewWithDataHandler>
|
|
27
|
+
</div>
|
|
28
|
+
</div>
|
|
29
|
+
</template>
|
|
30
|
+
|
|
31
|
+
<script>
|
|
32
|
+
import Search from "../shared/Search.vue";
|
|
33
|
+
|
|
34
|
+
import ListViewWithDataHandler from "@nixweb/nixloc-ui/src/component/template/ListViewWithDataHandler.vue";
|
|
35
|
+
|
|
36
|
+
import { mapGetters, mapMutations } from "vuex";
|
|
37
|
+
|
|
38
|
+
export default {
|
|
39
|
+
name: "ViewTemplateConfiguration",
|
|
40
|
+
components: { Search, ListViewWithDataHandler },
|
|
41
|
+
props: {
|
|
42
|
+
templateList: Object,
|
|
43
|
+
propsParam: Object,
|
|
44
|
+
showSearch: {
|
|
45
|
+
type: Boolean,
|
|
46
|
+
default: true,
|
|
47
|
+
},
|
|
48
|
+
showHorizontalFilter: {
|
|
49
|
+
type: Boolean,
|
|
50
|
+
default: true,
|
|
51
|
+
},
|
|
52
|
+
buttonRemove: {
|
|
53
|
+
type: Boolean,
|
|
54
|
+
default: true,
|
|
55
|
+
},
|
|
56
|
+
},
|
|
57
|
+
created() {
|
|
58
|
+
this.addLoading("loadingLine");
|
|
59
|
+
},
|
|
60
|
+
methods: {
|
|
61
|
+
...mapMutations("generic", ["addLoading"]),
|
|
62
|
+
},
|
|
63
|
+
};
|
|
64
|
+
</script>
|
|
@@ -26,7 +26,7 @@
|
|
|
26
26
|
type="primary"
|
|
27
27
|
title="Buscar"
|
|
28
28
|
classIcon="fas fa-file-search"
|
|
29
|
-
:disabled="
|
|
29
|
+
:disabled="btnSearchDisabled || !rulesIsValid"
|
|
30
30
|
size="medium"
|
|
31
31
|
:clicked="getAll"
|
|
32
32
|
/>
|
|
@@ -38,7 +38,7 @@
|
|
|
38
38
|
title="Salvar"
|
|
39
39
|
classIcon="fas fa-save"
|
|
40
40
|
size="small"
|
|
41
|
-
:disabled="isLoading || !rulesIsValid"
|
|
41
|
+
:disabled="isLoading || btnSaveDisabled || !rulesIsValid"
|
|
42
42
|
:params="{ name: 'save', title: 'Salvar', width: 550 }"
|
|
43
43
|
:clicked="executeOpenModal"
|
|
44
44
|
/>
|
|
@@ -83,7 +83,11 @@
|
|
|
83
83
|
</Alert>
|
|
84
84
|
</div>
|
|
85
85
|
<div class="body-report" v-show="showBodyReport && rulesIsValid">
|
|
86
|
-
<
|
|
86
|
+
<Report
|
|
87
|
+
:header="content.headerTable"
|
|
88
|
+
:data="content.data"
|
|
89
|
+
:totalization="content.totalization"
|
|
90
|
+
/>
|
|
87
91
|
</div>
|
|
88
92
|
</div>
|
|
89
93
|
</Panel>
|
|
@@ -120,7 +124,7 @@ import Button from "@nixweb/nixloc-ui/src/component/forms/Button";
|
|
|
120
124
|
import Modal from "@nixweb/nixloc-ui/src/component/forms/Modal";
|
|
121
125
|
import Alert from "@nixweb/nixloc-ui/src/component/layout/Alert";
|
|
122
126
|
import Tags from "@nixweb/nixloc-ui/src/component/shared/query-builder/Tags.vue";
|
|
123
|
-
import
|
|
127
|
+
import Report from "../shared/Report.vue";
|
|
124
128
|
|
|
125
129
|
import ReportCreateUpdate from "@nixweb/nixloc-ui/src/component/template/ReportCreateUpdate.vue";
|
|
126
130
|
import Fields from "@nixweb/nixloc-ui/src/component/shared/query-builder/Fields.vue";
|
|
@@ -143,7 +147,7 @@ export default {
|
|
|
143
147
|
Modal,
|
|
144
148
|
Alert,
|
|
145
149
|
Tags,
|
|
146
|
-
|
|
150
|
+
Report,
|
|
147
151
|
ReportCreateUpdate,
|
|
148
152
|
Fields,
|
|
149
153
|
Rules,
|
|
@@ -156,7 +160,7 @@ export default {
|
|
|
156
160
|
headerTable: [],
|
|
157
161
|
data: [],
|
|
158
162
|
totalPages: [],
|
|
159
|
-
totalization:
|
|
163
|
+
totalization: {},
|
|
160
164
|
noDataReturned: false,
|
|
161
165
|
},
|
|
162
166
|
baseParams: {
|
|
@@ -170,7 +174,8 @@ export default {
|
|
|
170
174
|
title: "",
|
|
171
175
|
width: 0,
|
|
172
176
|
},
|
|
173
|
-
|
|
177
|
+
btnSearchDisabled: false,
|
|
178
|
+
btnSaveDisabled: true,
|
|
174
179
|
isLoading: false,
|
|
175
180
|
showBodyReport: false,
|
|
176
181
|
};
|
|
@@ -184,7 +189,7 @@ export default {
|
|
|
184
189
|
|
|
185
190
|
if (this.id) this.getById();
|
|
186
191
|
|
|
187
|
-
if (!this.id) this.
|
|
192
|
+
if (!this.id) this.removeLoadingWithTime();
|
|
188
193
|
},
|
|
189
194
|
beforeDestroy() {
|
|
190
195
|
this.removeInitialReportCustom();
|
|
@@ -206,15 +211,18 @@ export default {
|
|
|
206
211
|
selectedRules: query.selectedRules,
|
|
207
212
|
};
|
|
208
213
|
this.addInitialReportCustom(report);
|
|
209
|
-
this.
|
|
214
|
+
this.removeLoadingWithTime();
|
|
210
215
|
});
|
|
211
216
|
},
|
|
212
217
|
getAll() {
|
|
213
|
-
this.
|
|
218
|
+
this.btnSearchDisabled = true;
|
|
214
219
|
|
|
215
220
|
if (this.rulesIsValid) {
|
|
216
221
|
this.getTotalRecords();
|
|
217
222
|
this.removeLoading(["btnSearchReport"]);
|
|
223
|
+
|
|
224
|
+
if (this.oDataFilter.totalization) this.totalization();
|
|
225
|
+
if (!this.oDataFilter.totalization) this.content.totalization = {};
|
|
218
226
|
}
|
|
219
227
|
},
|
|
220
228
|
getTotalRecords() {
|
|
@@ -237,10 +245,20 @@ export default {
|
|
|
237
245
|
this.showBodyReport = true;
|
|
238
246
|
});
|
|
239
247
|
},
|
|
248
|
+
totalization() {
|
|
249
|
+
let params = { url: this.urlTotalization };
|
|
250
|
+
this.getApiOdata(params).then((response) => {
|
|
251
|
+
const result = Object.entries(response[0]);
|
|
252
|
+
this.content.totalization = result;
|
|
253
|
+
});
|
|
254
|
+
},
|
|
240
255
|
loadingOnlyIfOnePage(data) {
|
|
241
256
|
this.content.data = data;
|
|
242
|
-
this.
|
|
243
|
-
|
|
257
|
+
this.btnSearchDisabled = true;
|
|
258
|
+
let self = this;
|
|
259
|
+
setTimeout(function () {
|
|
260
|
+
self.isLoading = false;
|
|
261
|
+
}, 350);
|
|
244
262
|
},
|
|
245
263
|
loadingOnlyIfManyPages() {
|
|
246
264
|
let seq = 0;
|
|
@@ -280,6 +298,13 @@ export default {
|
|
|
280
298
|
this.hideModal("templateReport");
|
|
281
299
|
this.removeLoading(["btnApplyFieldsAndRules"]);
|
|
282
300
|
},
|
|
301
|
+
removeLoadingWithTime() {
|
|
302
|
+
let self = this;
|
|
303
|
+
setTimeout(function () {
|
|
304
|
+
self.btnSaveDisabled = true;
|
|
305
|
+
self.removeLoading(["panel"]);
|
|
306
|
+
}, 350);
|
|
307
|
+
},
|
|
283
308
|
},
|
|
284
309
|
computed: {
|
|
285
310
|
...mapGetters("generic", ["showModal", "event"]),
|
|
@@ -297,11 +322,27 @@ export default {
|
|
|
297
322
|
let baseUrl = `${this.templateList.urlGetApi}?${this.oDataSelect}&${this.oDataOrderBy}&${this.oDataFilter.query}&$skip=${skip}&$top=${this.baseParams.totalPerPage}&$count=true`;
|
|
298
323
|
return baseUrl.replace("&&", "&");
|
|
299
324
|
},
|
|
325
|
+
urlTotalization() {
|
|
326
|
+
let query = this.oDataFilter.query
|
|
327
|
+
? `$apply=filter(${this.oDataFilter.query.replace("$filter=", "")})/`
|
|
328
|
+
: "$apply=";
|
|
329
|
+
let baseUrl = `${
|
|
330
|
+
this.templateList.urlGetApi
|
|
331
|
+
}?${query}aggregate(${this.oDataFilter.totalization.replace(",", "")})`;
|
|
332
|
+
return baseUrl;
|
|
333
|
+
},
|
|
300
334
|
liveTotalRecords() {
|
|
301
335
|
return this.content.data.length;
|
|
302
336
|
},
|
|
303
337
|
},
|
|
304
338
|
watch: {
|
|
339
|
+
event: {
|
|
340
|
+
handler(event) {
|
|
341
|
+
console.log(event);
|
|
342
|
+
if (event.name == "savedReport") this.btnSaveDisabled = true;
|
|
343
|
+
},
|
|
344
|
+
deep: true,
|
|
345
|
+
},
|
|
305
346
|
"content.totalPages": {
|
|
306
347
|
handler(totalPages) {
|
|
307
348
|
if (totalPages.length > 0) {
|
|
@@ -316,18 +357,21 @@ export default {
|
|
|
316
357
|
},
|
|
317
358
|
oDataFilter: {
|
|
318
359
|
handler(totalPages) {
|
|
360
|
+
this.btnSearchDisabled = false;
|
|
319
361
|
this.btnSaveDisabled = false;
|
|
320
362
|
},
|
|
321
363
|
deep: true,
|
|
322
364
|
},
|
|
323
365
|
oDataSelect: {
|
|
324
366
|
handler(totalPages) {
|
|
367
|
+
this.btnSearchDisabled = false;
|
|
325
368
|
this.btnSaveDisabled = false;
|
|
326
369
|
},
|
|
327
370
|
deep: true,
|
|
328
371
|
},
|
|
329
372
|
oDataOrderBy: {
|
|
330
373
|
handler(totalPages) {
|
|
374
|
+
this.btnSearchDisabled = false;
|
|
331
375
|
this.btnSaveDisabled = false;
|
|
332
376
|
},
|
|
333
377
|
deep: true,
|
|
@@ -1,32 +1,32 @@
|
|
|
1
|
-
<template>
|
|
2
|
-
<div>
|
|
3
|
-
<Panel
|
|
4
|
-
:module="panel.module"
|
|
5
|
-
:title="panel.title"
|
|
6
|
-
:showFilter="panel.showFilter"
|
|
7
|
-
:showSearch="panel.showSearch"
|
|
8
|
-
:showButtons="panel.showButtons"
|
|
9
|
-
>
|
|
10
|
-
<div slot="content-buttons">
|
|
11
|
-
<slot name="content-buttons"></slot>
|
|
12
|
-
</div>
|
|
13
|
-
<div slot="content-main">
|
|
14
|
-
<slot name="content-main"></slot>
|
|
15
|
-
</div>
|
|
16
|
-
</Panel>
|
|
17
|
-
<SaveCancel :formName="panel.formName" />
|
|
18
|
-
</div>
|
|
19
|
-
</template>
|
|
20
|
-
|
|
21
|
-
<script>
|
|
22
|
-
import Panel from "@nixweb/nixloc-ui/src/component/layout/Panel";
|
|
23
|
-
import SaveCancel from "@nixweb/nixloc-ui/src/component/shared/SaveCancel";
|
|
24
|
-
|
|
25
|
-
export default {
|
|
26
|
-
name: "ViewTemplateCrud",
|
|
27
|
-
components: { Panel, SaveCancel },
|
|
28
|
-
props: {
|
|
29
|
-
panel: Object,
|
|
30
|
-
},
|
|
31
|
-
};
|
|
32
|
-
</script>
|
|
1
|
+
<template>
|
|
2
|
+
<div>
|
|
3
|
+
<Panel
|
|
4
|
+
:module="panel.module"
|
|
5
|
+
:title="panel.title"
|
|
6
|
+
:showFilter="panel.showFilter"
|
|
7
|
+
:showSearch="panel.showSearch"
|
|
8
|
+
:showButtons="panel.showButtons"
|
|
9
|
+
>
|
|
10
|
+
<div slot="content-buttons">
|
|
11
|
+
<slot name="content-buttons"></slot>
|
|
12
|
+
</div>
|
|
13
|
+
<div slot="content-main">
|
|
14
|
+
<slot name="content-main"></slot>
|
|
15
|
+
</div>
|
|
16
|
+
</Panel>
|
|
17
|
+
<SaveCancel :formName="panel.formName" />
|
|
18
|
+
</div>
|
|
19
|
+
</template>
|
|
20
|
+
|
|
21
|
+
<script>
|
|
22
|
+
import Panel from "@nixweb/nixloc-ui/src/component/layout/Panel";
|
|
23
|
+
import SaveCancel from "@nixweb/nixloc-ui/src/component/shared/SaveCancel";
|
|
24
|
+
|
|
25
|
+
export default {
|
|
26
|
+
name: "ViewTemplateCrud",
|
|
27
|
+
components: { Panel, SaveCancel },
|
|
28
|
+
props: {
|
|
29
|
+
panel: Object,
|
|
30
|
+
},
|
|
31
|
+
};
|
|
32
|
+
</script>
|
|
@@ -1,56 +1,56 @@
|
|
|
1
|
-
<template>
|
|
2
|
-
<div>
|
|
3
|
-
<Panel
|
|
4
|
-
:module="panel.module"
|
|
5
|
-
:title="panel.title"
|
|
6
|
-
:showVerticalFilter="panel.showVerticalFilter"
|
|
7
|
-
:showSearch="panel.showSearch"
|
|
8
|
-
:showButtons="panel.showButtons"
|
|
9
|
-
>
|
|
10
|
-
<div slot="content-filter-vertical">
|
|
11
|
-
<slot name="content-filter-vertical"></slot>
|
|
12
|
-
</div>
|
|
13
|
-
<div slot="content-buttons">
|
|
14
|
-
<slot name="content-buttons"></slot>
|
|
15
|
-
</div>
|
|
16
|
-
<div slot="content-main">
|
|
17
|
-
<Molded>
|
|
18
|
-
<ListViewWithDataHandler
|
|
19
|
-
:templateList="templateList"
|
|
20
|
-
:buttonRemove="buttonRemove"
|
|
21
|
-
>
|
|
22
|
-
<div slot="content-buttons-table-header">
|
|
23
|
-
<slot name="content-buttons-table-header"></slot>
|
|
24
|
-
</div>
|
|
25
|
-
<div slot="content-filter-horizontal">
|
|
26
|
-
<slot name="content-filter-horizontal"></slot>
|
|
27
|
-
</div>
|
|
28
|
-
<div slot="content-buttons-table">
|
|
29
|
-
<slot name="content-buttons-table"></slot>
|
|
30
|
-
</div>
|
|
31
|
-
</ListViewWithDataHandler>
|
|
32
|
-
</Molded>
|
|
33
|
-
</div>
|
|
34
|
-
</Panel>
|
|
35
|
-
</div>
|
|
36
|
-
</template>
|
|
37
|
-
|
|
38
|
-
<script>
|
|
39
|
-
import Panel from "@nixweb/nixloc-ui/src/component/layout/Panel.vue";
|
|
40
|
-
import Molded from "@nixweb/nixloc-ui/src/component/layout/Molded";
|
|
41
|
-
|
|
42
|
-
import ListViewWithDataHandler from "@nixweb/nixloc-ui/src/component/template/ListViewWithDataHandler.vue";
|
|
43
|
-
|
|
44
|
-
export default {
|
|
45
|
-
name: "TemplateView",
|
|
46
|
-
components: { Panel, Molded, ListViewWithDataHandler },
|
|
47
|
-
props: {
|
|
48
|
-
panel: Object,
|
|
49
|
-
templateList: Object,
|
|
50
|
-
buttonRemove: {
|
|
51
|
-
type: Boolean,
|
|
52
|
-
default: true,
|
|
53
|
-
},
|
|
54
|
-
},
|
|
55
|
-
};
|
|
56
|
-
</script>
|
|
1
|
+
<template>
|
|
2
|
+
<div>
|
|
3
|
+
<Panel
|
|
4
|
+
:module="panel.module"
|
|
5
|
+
:title="panel.title"
|
|
6
|
+
:showVerticalFilter="panel.showVerticalFilter"
|
|
7
|
+
:showSearch="panel.showSearch"
|
|
8
|
+
:showButtons="panel.showButtons"
|
|
9
|
+
>
|
|
10
|
+
<div slot="content-filter-vertical">
|
|
11
|
+
<slot name="content-filter-vertical"></slot>
|
|
12
|
+
</div>
|
|
13
|
+
<div slot="content-buttons">
|
|
14
|
+
<slot name="content-buttons"></slot>
|
|
15
|
+
</div>
|
|
16
|
+
<div slot="content-main">
|
|
17
|
+
<Molded>
|
|
18
|
+
<ListViewWithDataHandler
|
|
19
|
+
:templateList="templateList"
|
|
20
|
+
:buttonRemove="buttonRemove"
|
|
21
|
+
>
|
|
22
|
+
<div slot="content-buttons-table-header">
|
|
23
|
+
<slot name="content-buttons-table-header"></slot>
|
|
24
|
+
</div>
|
|
25
|
+
<div slot="content-filter-horizontal">
|
|
26
|
+
<slot name="content-filter-horizontal"></slot>
|
|
27
|
+
</div>
|
|
28
|
+
<div slot="content-buttons-table">
|
|
29
|
+
<slot name="content-buttons-table"></slot>
|
|
30
|
+
</div>
|
|
31
|
+
</ListViewWithDataHandler>
|
|
32
|
+
</Molded>
|
|
33
|
+
</div>
|
|
34
|
+
</Panel>
|
|
35
|
+
</div>
|
|
36
|
+
</template>
|
|
37
|
+
|
|
38
|
+
<script>
|
|
39
|
+
import Panel from "@nixweb/nixloc-ui/src/component/layout/Panel.vue";
|
|
40
|
+
import Molded from "@nixweb/nixloc-ui/src/component/layout/Molded";
|
|
41
|
+
|
|
42
|
+
import ListViewWithDataHandler from "@nixweb/nixloc-ui/src/component/template/ListViewWithDataHandler.vue";
|
|
43
|
+
|
|
44
|
+
export default {
|
|
45
|
+
name: "TemplateView",
|
|
46
|
+
components: { Panel, Molded, ListViewWithDataHandler },
|
|
47
|
+
props: {
|
|
48
|
+
panel: Object,
|
|
49
|
+
templateList: Object,
|
|
50
|
+
buttonRemove: {
|
|
51
|
+
type: Boolean,
|
|
52
|
+
default: true,
|
|
53
|
+
},
|
|
54
|
+
},
|
|
55
|
+
};
|
|
56
|
+
</script>
|
|
@@ -10,6 +10,7 @@
|
|
|
10
10
|
:maxLength="20"
|
|
11
11
|
:required="required"
|
|
12
12
|
v-model="contact.phone"
|
|
13
|
+
:markFormDirty="markFormDirty"
|
|
13
14
|
/>
|
|
14
15
|
</b-col>
|
|
15
16
|
<b-col xs="12" sm="12" md="12" lg="4" xl="4">
|
|
@@ -21,6 +22,7 @@
|
|
|
21
22
|
:maxLength="100"
|
|
22
23
|
:required="required"
|
|
23
24
|
v-model="contact.webSite"
|
|
25
|
+
:markFormDirty="markFormDirty"
|
|
24
26
|
/>
|
|
25
27
|
</b-col>
|
|
26
28
|
<b-col xs="12" sm="12" md="12" lg="4" xl="4">
|
|
@@ -32,6 +34,7 @@
|
|
|
32
34
|
:maxLength="100"
|
|
33
35
|
:required="required"
|
|
34
36
|
v-model="contact.email"
|
|
37
|
+
:markFormDirty="markFormDirty"
|
|
35
38
|
/>
|
|
36
39
|
</b-col>
|
|
37
40
|
</b-row>
|
|
@@ -53,6 +56,10 @@ export default {
|
|
|
53
56
|
type: Boolean,
|
|
54
57
|
default: false,
|
|
55
58
|
},
|
|
59
|
+
markFormDirty: {
|
|
60
|
+
type: Boolean,
|
|
61
|
+
default: true,
|
|
62
|
+
},
|
|
56
63
|
value: Object,
|
|
57
64
|
},
|
|
58
65
|
components: { InputText, Button },
|
|
@@ -5,11 +5,13 @@
|
|
|
5
5
|
<RadioGroup
|
|
6
6
|
field="typePerson"
|
|
7
7
|
:formName="formName"
|
|
8
|
+
v-show="showTypePerson"
|
|
8
9
|
:options="[
|
|
9
10
|
{ text: 'Física', value: 1 },
|
|
10
11
|
{ text: 'Jurídica', value: 2 },
|
|
11
12
|
]"
|
|
12
13
|
v-model="person.typePerson"
|
|
14
|
+
:markFormDirty="markFormDirty"
|
|
13
15
|
/>
|
|
14
16
|
</b-col>
|
|
15
17
|
</b-row>
|
|
@@ -23,6 +25,7 @@
|
|
|
23
25
|
:maxLength="30"
|
|
24
26
|
:required="required"
|
|
25
27
|
v-model="person.document"
|
|
28
|
+
:markFormDirty="markFormDirty"
|
|
26
29
|
><div class="glyphicon margin-button">
|
|
27
30
|
<Button
|
|
28
31
|
v-if="person.typePerson == 2"
|
|
@@ -43,6 +46,7 @@
|
|
|
43
46
|
:maxLength="50"
|
|
44
47
|
:required="required"
|
|
45
48
|
v-model="person.stateInscription"
|
|
49
|
+
:markFormDirty="markFormDirty"
|
|
46
50
|
/>
|
|
47
51
|
</b-col>
|
|
48
52
|
<b-col xs="12" sm="12" md="12" lg="4" xl="4">
|
|
@@ -54,6 +58,7 @@
|
|
|
54
58
|
:maxLength="50"
|
|
55
59
|
:required="required"
|
|
56
60
|
v-model="person.municipalInscription"
|
|
61
|
+
:markFormDirty="markFormDirty"
|
|
57
62
|
/>
|
|
58
63
|
</b-col>
|
|
59
64
|
</b-row>
|
|
@@ -67,6 +72,7 @@
|
|
|
67
72
|
:required="true"
|
|
68
73
|
:maxLength="100"
|
|
69
74
|
v-model="person.companyName"
|
|
75
|
+
:markFormDirty="markFormDirty"
|
|
70
76
|
/>
|
|
71
77
|
</b-col>
|
|
72
78
|
<b-col xs="12" sm="12" md="12" lg="4" xl="4">
|
|
@@ -77,6 +83,7 @@
|
|
|
77
83
|
:required="true"
|
|
78
84
|
:maxLength="100"
|
|
79
85
|
v-model="person.tradeName"
|
|
86
|
+
:markFormDirty="markFormDirty"
|
|
80
87
|
/>
|
|
81
88
|
</b-col>
|
|
82
89
|
</b-row>
|
|
@@ -99,6 +106,14 @@ export default {
|
|
|
99
106
|
type: Boolean,
|
|
100
107
|
default: false,
|
|
101
108
|
},
|
|
109
|
+
showTypePerson: {
|
|
110
|
+
type: Boolean,
|
|
111
|
+
default: true,
|
|
112
|
+
},
|
|
113
|
+
markFormDirty: {
|
|
114
|
+
type: Boolean,
|
|
115
|
+
default: true,
|
|
116
|
+
},
|
|
102
117
|
value: Object,
|
|
103
118
|
},
|
|
104
119
|
components: { RadioGroup, InputText, Button },
|
package/src/config/axios.js
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import axios from "axios";
|
|
2
|
-
|
|
3
|
-
const BASE_URL = process.env.VUE_APP_API_URL;
|
|
4
|
-
|
|
5
|
-
const api = axios.create({
|
|
6
|
-
baseURL: BASE_URL,
|
|
7
|
-
});
|
|
8
|
-
|
|
9
|
-
export default api;
|
|
1
|
+
import axios from "axios";
|
|
2
|
+
|
|
3
|
+
const BASE_URL = process.env.VUE_APP_API_URL;
|
|
4
|
+
|
|
5
|
+
const api = axios.create({
|
|
6
|
+
baseURL: BASE_URL,
|
|
7
|
+
});
|
|
8
|
+
|
|
9
|
+
export default api;
|
package/src/config/dicas.js
CHANGED
|
@@ -1,15 +1,15 @@
|
|
|
1
|
-
const dicas = [];
|
|
2
|
-
|
|
3
|
-
const manutencao = [
|
|
4
|
-
// { formName: "opcoesFaturamento", field: "unificar", title: "Unificar Cliente", description: "Ao marcar essa opção" },
|
|
5
|
-
|
|
6
|
-
];
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
manutencao.forEach(function (obj) {
|
|
10
|
-
dicas.push(obj);
|
|
11
|
-
});
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
1
|
+
const dicas = [];
|
|
2
|
+
|
|
3
|
+
const manutencao = [
|
|
4
|
+
// { formName: "opcoesFaturamento", field: "unificar", title: "Unificar Cliente", description: "Ao marcar essa opção" },
|
|
5
|
+
|
|
6
|
+
];
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
manutencao.forEach(function (obj) {
|
|
10
|
+
dicas.push(obj);
|
|
11
|
+
});
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
|
|
15
15
|
export default dicas;
|
package/src/config/router.js
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
|
-
import Vue from 'vue'
|
|
2
|
-
import Router from 'vue-router'
|
|
3
|
-
|
|
4
|
-
Vue.use(Router)
|
|
5
|
-
|
|
6
|
-
const router = new Router({
|
|
7
|
-
mode: 'history',
|
|
8
|
-
routes: [
|
|
9
|
-
{ path: '/', redirect: { name: "" } },
|
|
10
|
-
|
|
11
|
-
],
|
|
12
|
-
})
|
|
13
|
-
|
|
1
|
+
import Vue from 'vue'
|
|
2
|
+
import Router from 'vue-router'
|
|
3
|
+
|
|
4
|
+
Vue.use(Router)
|
|
5
|
+
|
|
6
|
+
const router = new Router({
|
|
7
|
+
mode: 'history',
|
|
8
|
+
routes: [
|
|
9
|
+
{ path: '/', redirect: { name: "" } },
|
|
10
|
+
|
|
11
|
+
],
|
|
12
|
+
})
|
|
13
|
+
|
|
14
14
|
export default router
|