@bildvitta/quasar-ui-asteroid 3.0.0-alpha.3 → 3.0.0-beta.3
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/dist/api/QasBtn.json +5 -2
- package/dist/api/QasDelete.json +5 -0
- package/dist/api/QasFilters.json +4 -0
- package/dist/api/QasFormView.json +6 -4
- package/dist/api/QasInput.json +16 -1
- package/dist/api/QasPasswordInput.json +2 -1
- package/dist/api/QasSignatureUploader.json +7 -0
- package/dist/asteroid.cjs.css +1 -1
- package/dist/asteroid.cjs.js +792 -653
- package/dist/asteroid.cjs.min.js +2 -2
- package/dist/asteroid.esm.css +1 -1
- package/dist/asteroid.esm.js +794 -654
- package/dist/asteroid.esm.min.js +2 -2
- package/dist/asteroid.umd.css +1 -1
- package/dist/asteroid.umd.js +794 -654
- package/dist/asteroid.umd.min.js +2 -2
- package/dist/vetur/asteroid-attributes.json +31 -3
- package/dist/vetur/asteroid-tags.json +11 -4
- package/package.json +1 -1
- package/src/asteroid.js +1 -0
- package/src/components/actions/QasActions.vue +1 -5
- package/src/components/actions-menu/QasActionsMenu.vue +3 -5
- package/src/components/app-menu/QasAppMenu.vue +1 -4
- package/src/components/btn/QasBtn.vue +12 -11
- package/src/components/btn/QasBtn.yml +4 -1
- package/src/components/delete/QasDelete.vue +23 -1
- package/src/components/delete/QasDelete.yml +4 -0
- package/src/components/dialog/QasDialog.vue +4 -8
- package/src/components/field/QasField.vue +1 -2
- package/src/components/filters/QasFilters.vue +6 -2
- package/src/components/filters/QasFilters.yml +4 -0
- package/src/components/form-view/QasFormView.vue +14 -14
- package/src/components/form-view/QasFormView.yml +8 -3
- package/src/components/gallery/QasGallery.vue +4 -8
- package/src/components/input/QasInput.vue +43 -2
- package/src/components/input/QasInput.yml +13 -1
- package/src/components/nested-fields/QasNestedFields.vue +47 -35
- package/src/components/page-header/QasPageHeader.vue +4 -2
- package/src/components/password-input/QasPasswordInput.vue +17 -26
- package/src/components/password-input/QasPasswordInput.yml +1 -1
- package/src/components/profile/QasProfile.vue +2 -5
- package/src/components/search-box/QasSearchBox.vue +6 -1
- package/src/components/select-list/QasSelectList.vue +12 -13
- package/src/components/signature-uploader/QasSignatureUploader.vue +35 -2
- package/src/components/signature-uploader/QasSignatureUploader.yml +5 -0
- package/src/components/table-generator/QasTableGenerator.vue +3 -6
- package/src/components/text-truncate/QasTextTruncate.vue +1 -4
- package/src/components/transfer/QasTransfer.vue +12 -13
- package/src/components/uploader/QasUploader.vue +1 -2
- package/src/composables/index.js +1 -0
- package/src/composables/useForm.js +3 -0
- package/src/composables/useHistory.js +46 -0
- package/src/css/design-system/button.scss +6 -0
- package/src/css/design-system/index.scss +2 -0
- package/src/css/design-system/typography.scss +91 -0
- package/src/directives/Test.js +13 -0
- package/src/helpers/filter-list-by-handle.js +31 -0
- package/src/helpers/filter-object-to-array.js +29 -0
- package/src/helpers/filter-object.js +2 -3
- package/src/helpers/index.js +2 -0
- package/src/index.scss +4 -2
- package/src/mixins/index.js +1 -3
- package/src/mixins/view.js +2 -0
- package/src/pages/Forbidden.vue +12 -0
- package/src/pages/NotFound.vue +12 -0
- package/src/plugins/index.js +2 -0
- package/src/plugins/screen/Screen.js +35 -0
- package/src/plugins/screen/Screen.yml +16 -0
- package/src/vue-plugin.js +12 -3
- package/src/css/transitions.scss +0 -12
- package/src/mixins/screen.js +0 -34
- package/src/store/history.js +0 -43
- package/src/store/index.js +0 -1
package/dist/asteroid.umd.js
CHANGED
|
@@ -1,358 +1,26 @@
|
|
|
1
1
|
/*!
|
|
2
|
-
* @bildvitta/quasar-ui-asteroid v3.0.0-
|
|
2
|
+
* @bildvitta/quasar-ui-asteroid v3.0.0-beta.3
|
|
3
3
|
* (c) 2022 Bild & Vitta <systemteam@bild.com.br>
|
|
4
4
|
* Released under the MIT License.
|
|
5
5
|
*/
|
|
6
6
|
(function (global, factory) {
|
|
7
|
-
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory(require('
|
|
8
|
-
typeof define === 'function' && define.amd ? define(['
|
|
9
|
-
(global = typeof globalThis !== 'undefined' ? globalThis : global || self, global["{{ umdExportName }}"] = factory(global.
|
|
10
|
-
})(this, (function (
|
|
7
|
+
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory(require('vue'), require('humps'), require('date-fns'), require('date-fns/locale'), require('quasar'), require('lodash-es'), require('autonumeric'), require('pica'), require('signature_pad'), require('vue-router'), require('fuse.js'), require('sortablejs'), require('@fawmi/vue-google-maps')) :
|
|
8
|
+
typeof define === 'function' && define.amd ? define(['vue', 'humps', 'date-fns', 'date-fns/locale', 'quasar', 'lodash-es', 'autonumeric', 'pica', 'signature_pad', 'vue-router', 'fuse.js', 'sortablejs', '@fawmi/vue-google-maps'], factory) :
|
|
9
|
+
(global = typeof globalThis !== 'undefined' ? globalThis : global || self, global["{{ umdExportName }}"] = factory(global.Vue, global.humps, global.dateFns, global.dateFnsLocale, global.Quasar, global._, global.AutoNumeric, global.Pica, global.SignaturePad, global.VueRouter, global.Fuse, global.Sortable, global.VueGoogleMaps));
|
|
10
|
+
})(this, (function (vue, humps, dateFns, locale, quasar, lodashEs, AutoNumeric, Pica, SignaturePad, vueRouter, Fuse, Sortable, VueGoogleMaps) { 'use strict';
|
|
11
11
|
|
|
12
12
|
function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
|
|
13
13
|
|
|
14
14
|
var AutoNumeric__default = /*#__PURE__*/_interopDefaultLegacy(AutoNumeric);
|
|
15
15
|
var Pica__default = /*#__PURE__*/_interopDefaultLegacy(Pica);
|
|
16
|
-
var api__default = /*#__PURE__*/_interopDefaultLegacy(api);
|
|
17
16
|
var SignaturePad__default = /*#__PURE__*/_interopDefaultLegacy(SignaturePad);
|
|
18
17
|
var Fuse__default = /*#__PURE__*/_interopDefaultLegacy(Fuse);
|
|
19
18
|
var Sortable__default = /*#__PURE__*/_interopDefaultLegacy(Sortable);
|
|
20
19
|
var VueGoogleMaps__default = /*#__PURE__*/_interopDefaultLegacy(VueGoogleMaps);
|
|
21
20
|
|
|
22
|
-
var contextMixin = {
|
|
23
|
-
computed: {
|
|
24
|
-
mx_context () {
|
|
25
|
-
const { limit, ordering, page, search, ...filters } = this.$route.query;
|
|
26
|
-
return { filters, limit, ordering, page: page ? parseInt(page) : 1, search }
|
|
27
|
-
}
|
|
28
|
-
}
|
|
29
|
-
};
|
|
30
|
-
|
|
31
|
-
const irregularClasses = ['col', 'col-auto', 'fit'];
|
|
32
|
-
|
|
33
|
-
var generatorMixin = {
|
|
34
|
-
props: {
|
|
35
|
-
columns: {
|
|
36
|
-
default: () => [],
|
|
37
|
-
type: [Array, String, Object]
|
|
38
|
-
},
|
|
39
|
-
|
|
40
|
-
fields: {
|
|
41
|
-
default: () => ({}),
|
|
42
|
-
type: Object
|
|
43
|
-
},
|
|
44
|
-
|
|
45
|
-
gutter: {
|
|
46
|
-
default: 'md',
|
|
47
|
-
type: [String, Boolean],
|
|
48
|
-
validator: value => ['xs', 'sm', 'md', 'lg', 'xl'].includes(value)
|
|
49
|
-
}
|
|
50
|
-
},
|
|
51
|
-
|
|
52
|
-
computed: {
|
|
53
|
-
mx_classes () {
|
|
54
|
-
const classes = ['row'];
|
|
55
|
-
|
|
56
|
-
if (this.gutter) {
|
|
57
|
-
classes.push(`q-col-gutter-${this.gutter}`);
|
|
58
|
-
}
|
|
59
|
-
|
|
60
|
-
return classes
|
|
61
|
-
}
|
|
62
|
-
},
|
|
63
|
-
|
|
64
|
-
methods: {
|
|
65
|
-
mx_getBreakpoint (columns) {
|
|
66
|
-
const classes = [];
|
|
67
|
-
const profiles = { col: 'col', xs: 'col-xs', sm: 'col-sm', md: 'col-md', lg: 'col-lg', xl: 'col-xl' };
|
|
68
|
-
const { fieldProps, classes: renamedClasses, ...formattedColumns } = columns || {};
|
|
69
|
-
|
|
70
|
-
for (const key in formattedColumns) {
|
|
71
|
-
const value = formattedColumns[key];
|
|
72
|
-
classes.push(irregularClasses.includes(value) ? value : `${profiles[key]}-${value}`);
|
|
73
|
-
}
|
|
74
|
-
|
|
75
|
-
return [...classes, renamedClasses]
|
|
76
|
-
},
|
|
77
|
-
|
|
78
|
-
mx_getFieldClass (index, isGridGenerator) {
|
|
79
|
-
if (typeof this.columns === 'string') {
|
|
80
|
-
return irregularClasses.includes(this.columns) ? this.columns : `col-${this.columns}`
|
|
81
|
-
}
|
|
82
|
-
|
|
83
|
-
return Array.isArray(this.columns)
|
|
84
|
-
? this.mx_handleColumnsByIndex(index, isGridGenerator)
|
|
85
|
-
: this.mx_handleColumnsByField(index, isGridGenerator)
|
|
86
|
-
},
|
|
87
|
-
|
|
88
|
-
mx_handleColumnsByField (index, isGridGenerator) {
|
|
89
|
-
if (!this.columns[index]) {
|
|
90
|
-
return this.mx_setDefaultColumnClass(isGridGenerator)
|
|
91
|
-
}
|
|
92
|
-
|
|
93
|
-
return this.mx_getBreakpoint(this.columns[index])
|
|
94
|
-
},
|
|
95
|
-
|
|
96
|
-
mx_handleColumnsByIndex (index, isGridGenerator) {
|
|
97
|
-
const fields = isGridGenerator ? this.fields : this.groupedFields.visible;
|
|
98
|
-
|
|
99
|
-
if (!Array.isArray(fields)) {
|
|
100
|
-
index = Object.keys(fields).findIndex(field => field === index);
|
|
101
|
-
}
|
|
102
|
-
|
|
103
|
-
const length = this.columns.length;
|
|
104
|
-
|
|
105
|
-
if (!length) {
|
|
106
|
-
return this.mx_setDefaultColumnClass(isGridGenerator)
|
|
107
|
-
}
|
|
108
|
-
|
|
109
|
-
return this.mx_getBreakpoint(this.columns[index])
|
|
110
|
-
},
|
|
111
|
-
|
|
112
|
-
mx_setDefaultColumnClass (isGridGenerator) {
|
|
113
|
-
return isGridGenerator ? 'col-6 col-xs-12 col-sm-4' : 'col-6'
|
|
114
|
-
}
|
|
115
|
-
}
|
|
116
|
-
};
|
|
117
|
-
|
|
118
|
-
const levels = {
|
|
119
|
-
0: {
|
|
120
|
-
color: 'negative',
|
|
121
|
-
label: 'Muito fraco',
|
|
122
|
-
progress: 0.05,
|
|
123
|
-
textClass: 'text-negative'
|
|
124
|
-
},
|
|
125
|
-
|
|
126
|
-
1: {
|
|
127
|
-
color: 'warning',
|
|
128
|
-
label: 'Fraco',
|
|
129
|
-
progress: 0.25,
|
|
130
|
-
textClass: 'text-warning'
|
|
131
|
-
},
|
|
132
|
-
|
|
133
|
-
2: {
|
|
134
|
-
color: 'warning',
|
|
135
|
-
label: 'Bom',
|
|
136
|
-
progress: 0.5,
|
|
137
|
-
textClass: 'text-warning'
|
|
138
|
-
},
|
|
139
|
-
|
|
140
|
-
3: {
|
|
141
|
-
color: 'positive',
|
|
142
|
-
label: 'Forte',
|
|
143
|
-
progress: 0.75,
|
|
144
|
-
textClass: 'text-positive'
|
|
145
|
-
},
|
|
146
|
-
|
|
147
|
-
4: {
|
|
148
|
-
color: 'positive',
|
|
149
|
-
label: 'Muito forte',
|
|
150
|
-
progress: 1,
|
|
151
|
-
textClass: 'text-positive'
|
|
152
|
-
}
|
|
153
|
-
};
|
|
154
|
-
|
|
155
|
-
var passwordMixin = {
|
|
156
|
-
props: {
|
|
157
|
-
levels: {
|
|
158
|
-
default: () => levels,
|
|
159
|
-
type: Object
|
|
160
|
-
},
|
|
161
|
-
|
|
162
|
-
// https://developer.mozilla.org/en-US/docs/Web/HTML/Attributes/minlength
|
|
163
|
-
minlength: {
|
|
164
|
-
default: 8,
|
|
165
|
-
type: [Number, String]
|
|
166
|
-
},
|
|
167
|
-
|
|
168
|
-
specials: {
|
|
169
|
-
default: /[!@#$%^&*()_+\-=[\]{}|;:'",<.>/?`~]/g,
|
|
170
|
-
type: RegExp
|
|
171
|
-
},
|
|
172
|
-
|
|
173
|
-
trackColor: {
|
|
174
|
-
default: 'blue-grey-1',
|
|
175
|
-
type: String
|
|
176
|
-
},
|
|
177
|
-
|
|
178
|
-
useLowercase: {
|
|
179
|
-
default: true,
|
|
180
|
-
type: Boolean
|
|
181
|
-
},
|
|
182
|
-
|
|
183
|
-
useNumbers: {
|
|
184
|
-
default: true,
|
|
185
|
-
type: Boolean
|
|
186
|
-
},
|
|
187
|
-
|
|
188
|
-
useSpecial: {
|
|
189
|
-
default: true,
|
|
190
|
-
type: Boolean
|
|
191
|
-
},
|
|
192
|
-
|
|
193
|
-
useUppercase: {
|
|
194
|
-
default: true,
|
|
195
|
-
type: Boolean
|
|
196
|
-
}
|
|
197
|
-
}
|
|
198
|
-
};
|
|
199
|
-
|
|
200
|
-
var screenMixin = {
|
|
201
|
-
// TODO: Esses nomes precisam ser alterados para algo mais inteligente.
|
|
202
|
-
|
|
203
|
-
computed: {
|
|
204
|
-
mx_isSmall () {
|
|
205
|
-
// until 599
|
|
206
|
-
return this.$q.screen.xs
|
|
207
|
-
},
|
|
208
|
-
|
|
209
|
-
mx_isMedium () {
|
|
210
|
-
// from 600 until 1023
|
|
211
|
-
return this.$q.screen.sm
|
|
212
|
-
},
|
|
213
|
-
|
|
214
|
-
mx_isLarge () {
|
|
215
|
-
// from 1024 until the limit
|
|
216
|
-
return this.$q.screen.gt.sm
|
|
217
|
-
},
|
|
218
|
-
|
|
219
|
-
mx_untilMedium () {
|
|
220
|
-
// from 0 until 599
|
|
221
|
-
return this.$q.screen.lt.sm
|
|
222
|
-
},
|
|
223
|
-
|
|
224
|
-
mx_untilLarge () {
|
|
225
|
-
// from 0 until 1023
|
|
226
|
-
return this.$q.screen.lt.md
|
|
227
|
-
},
|
|
228
|
-
|
|
229
|
-
mx_isMobile () {
|
|
230
|
-
return this.$q.platform.is.mobile
|
|
231
|
-
}
|
|
232
|
-
}
|
|
233
|
-
};
|
|
234
|
-
|
|
235
|
-
var viewMixin = {
|
|
236
|
-
props: {
|
|
237
|
-
dialog: {
|
|
238
|
-
type: Boolean
|
|
239
|
-
},
|
|
240
|
-
|
|
241
|
-
entity: {
|
|
242
|
-
required: true,
|
|
243
|
-
type: String
|
|
244
|
-
},
|
|
245
|
-
|
|
246
|
-
url: {
|
|
247
|
-
default: '',
|
|
248
|
-
type: String
|
|
249
|
-
},
|
|
250
|
-
|
|
251
|
-
fields: {
|
|
252
|
-
default: () => ({}),
|
|
253
|
-
type: Object
|
|
254
|
-
},
|
|
255
|
-
|
|
256
|
-
errors: {
|
|
257
|
-
default: () => ({}),
|
|
258
|
-
type: Object
|
|
259
|
-
},
|
|
260
|
-
|
|
261
|
-
metadata: {
|
|
262
|
-
default: () => ({}),
|
|
263
|
-
type: Object
|
|
264
|
-
},
|
|
265
|
-
|
|
266
|
-
fetching: {
|
|
267
|
-
type: Boolean
|
|
268
|
-
}
|
|
269
|
-
},
|
|
270
|
-
|
|
271
|
-
emits: [
|
|
272
|
-
'update:fields',
|
|
273
|
-
'update:errors',
|
|
274
|
-
'update:metadata',
|
|
275
|
-
'update:fetching'
|
|
276
|
-
],
|
|
277
|
-
|
|
278
|
-
data () {
|
|
279
|
-
return {
|
|
280
|
-
mx_errors: {},
|
|
281
|
-
mx_fields: {},
|
|
282
|
-
mx_metadata: {},
|
|
283
|
-
|
|
284
|
-
mx_isFetching: false
|
|
285
|
-
}
|
|
286
|
-
},
|
|
287
|
-
|
|
288
|
-
watch: {
|
|
289
|
-
mx_isFetching (value) {
|
|
290
|
-
this.$emit('update:fetching', value);
|
|
291
|
-
}
|
|
292
|
-
},
|
|
293
|
-
|
|
294
|
-
computed: {
|
|
295
|
-
mx_componentTag () {
|
|
296
|
-
return this.dialog ? 'div' : 'q-page'
|
|
297
|
-
},
|
|
298
|
-
|
|
299
|
-
mx_componentClass () {
|
|
300
|
-
return !this.dialog && 'container spaced'
|
|
301
|
-
},
|
|
302
|
-
|
|
303
|
-
mx_hasFooterSlot () {
|
|
304
|
-
return !!(this.$slots.footer)
|
|
305
|
-
},
|
|
306
|
-
|
|
307
|
-
mx_hasHeaderSlot () {
|
|
308
|
-
return !!(this.$slots.header)
|
|
309
|
-
}
|
|
310
|
-
},
|
|
311
|
-
|
|
312
|
-
methods: {
|
|
313
|
-
mx_fetchError (error) {
|
|
314
|
-
const { response } = error;
|
|
315
|
-
const exception = response?.data?.exception || error.message;
|
|
316
|
-
|
|
317
|
-
this.$qas.error('Ops! Erro ao obter os dados.', exception);
|
|
318
|
-
|
|
319
|
-
const status = response?.status;
|
|
320
|
-
const redirect = ({ 403: 'Forbidden', 404: 'NotFound' })[status];
|
|
321
|
-
|
|
322
|
-
if (redirect) {
|
|
323
|
-
this.$router.replace({ name: redirect });
|
|
324
|
-
}
|
|
325
|
-
},
|
|
326
|
-
|
|
327
|
-
mx_setErrors (errors = {}) {
|
|
328
|
-
this.mx_errors = vue.markRaw(errors);
|
|
329
|
-
},
|
|
330
|
-
|
|
331
|
-
mx_setFields (fields = {}) {
|
|
332
|
-
for (const field in fields) {
|
|
333
|
-
fields[field].name = humps.camelize(fields[field].name);
|
|
334
|
-
}
|
|
335
|
-
|
|
336
|
-
this.mx_fields = vue.markRaw(fields);
|
|
337
|
-
},
|
|
338
|
-
|
|
339
|
-
mx_setMetadata (metadata = {}) {
|
|
340
|
-
this.mx_metadata = vue.markRaw(metadata);
|
|
341
|
-
},
|
|
342
|
-
|
|
343
|
-
mx_updateModels (models) {
|
|
344
|
-
for (const key in models) {
|
|
345
|
-
this.$emit(`update:${key}`, models[key]);
|
|
346
|
-
}
|
|
347
|
-
}
|
|
348
|
-
}
|
|
349
|
-
};
|
|
350
|
-
|
|
351
21
|
var script$L = {
|
|
352
22
|
name: 'QasActions',
|
|
353
23
|
|
|
354
|
-
mixins: [screenMixin],
|
|
355
|
-
|
|
356
24
|
props: {
|
|
357
25
|
align: {
|
|
358
26
|
default: 'end',
|
|
@@ -372,7 +40,7 @@
|
|
|
372
40
|
return [
|
|
373
41
|
`justify-${this.align}`,
|
|
374
42
|
`q-col-gutter-${this.gutter}`,
|
|
375
|
-
this.
|
|
43
|
+
this.$qas.screen.isSmall ? 'column reverse' : 'row'
|
|
376
44
|
]
|
|
377
45
|
}
|
|
378
46
|
}
|
|
@@ -400,28 +68,31 @@
|
|
|
400
68
|
var script$K = {
|
|
401
69
|
name: 'QasBtn',
|
|
402
70
|
|
|
403
|
-
mixins: [screenMixin],
|
|
404
|
-
|
|
405
|
-
inheritAttrs: false,
|
|
406
|
-
|
|
407
71
|
props: {
|
|
408
72
|
hideLabelOnSmallScreen: {
|
|
409
73
|
type: Boolean
|
|
74
|
+
},
|
|
75
|
+
|
|
76
|
+
label: {
|
|
77
|
+
type: String,
|
|
78
|
+
default: ''
|
|
410
79
|
}
|
|
411
80
|
},
|
|
412
81
|
|
|
413
82
|
computed: {
|
|
414
83
|
attributes () {
|
|
415
|
-
|
|
416
|
-
|
|
84
|
+
return {
|
|
85
|
+
...(this.showLabel && { label: this.label }),
|
|
86
|
+
...this.$attrs
|
|
87
|
+
}
|
|
417
88
|
},
|
|
418
89
|
|
|
419
90
|
hasLabel () {
|
|
420
|
-
return !!(this
|
|
91
|
+
return !!(this.label || this.$slots.default)
|
|
421
92
|
},
|
|
422
93
|
|
|
423
94
|
showLabel () {
|
|
424
|
-
return this.hasLabel && !(this.hideLabelOnSmallScreen && this.
|
|
95
|
+
return this.hasLabel && !(this.hideLabelOnSmallScreen && this.$qas.screen.isSmall)
|
|
425
96
|
},
|
|
426
97
|
|
|
427
98
|
slots () {
|
|
@@ -441,9 +112,7 @@
|
|
|
441
112
|
}, $options.attributes), vue.createSlots({
|
|
442
113
|
default: vue.withCtx(() => [
|
|
443
114
|
($options.showLabel)
|
|
444
|
-
? vue.renderSlot(_ctx.$slots, "default", { key: 0 }
|
|
445
|
-
vue.createTextVNode(vue.toDisplayString(_ctx.$attrs.label), 1 /* TEXT */)
|
|
446
|
-
])
|
|
115
|
+
? vue.renderSlot(_ctx.$slots, "default", { key: 0 })
|
|
447
116
|
: vue.createCommentVNode("v-if", true)
|
|
448
117
|
]),
|
|
449
118
|
_: 2 /* DYNAMIC */
|
|
@@ -541,10 +210,10 @@
|
|
|
541
210
|
"hide-label-on-small-screen": "",
|
|
542
211
|
icon: $props.icon,
|
|
543
212
|
label: $props.label,
|
|
544
|
-
outline: ""
|
|
213
|
+
outline: "",
|
|
214
|
+
padding: "md"
|
|
545
215
|
}, {
|
|
546
216
|
default: vue.withCtx(() => [
|
|
547
|
-
vue.createElementVNode("span", null, vue.toDisplayString($props.label), 1 /* TEXT */),
|
|
548
217
|
vue.createVNode(_component_q_menu, { class: "qas-actions-menu__menu" }, {
|
|
549
218
|
default: vue.withCtx(() => [
|
|
550
219
|
vue.createVNode(_component_q_list, {
|
|
@@ -567,8 +236,8 @@
|
|
|
567
236
|
vue.createElementVNode("div", _hoisted_1$r, [
|
|
568
237
|
vue.createVNode(_component_q_icon, {
|
|
569
238
|
name: item.icon,
|
|
570
|
-
size:
|
|
571
|
-
}, null, 8 /* PROPS */, ["name"
|
|
239
|
+
size: "sm"
|
|
240
|
+
}, null, 8 /* PROPS */, ["name"]),
|
|
572
241
|
vue.createElementVNode("div", null, vue.toDisplayString(item.label), 1 /* TEXT */)
|
|
573
242
|
])
|
|
574
243
|
]),
|
|
@@ -590,7 +259,10 @@
|
|
|
590
259
|
vue.createVNode(_component_q_item_section, null, {
|
|
591
260
|
default: vue.withCtx(() => [
|
|
592
261
|
vue.createElementVNode("div", _hoisted_2$k, [
|
|
593
|
-
vue.createVNode(_component_q_icon, {
|
|
262
|
+
vue.createVNode(_component_q_icon, {
|
|
263
|
+
name: $props.deleteIcon,
|
|
264
|
+
size: "sm"
|
|
265
|
+
}, null, 8 /* PROPS */, ["name"]),
|
|
594
266
|
vue.createElementVNode("div", null, vue.toDisplayString($props.deleteLabel), 1 /* TEXT */)
|
|
595
267
|
])
|
|
596
268
|
]),
|
|
@@ -751,11 +423,10 @@
|
|
|
751
423
|
}
|
|
752
424
|
|
|
753
425
|
/**
|
|
754
|
-
*
|
|
755
|
-
* Função para filtrar propriedades espessificas dentro de um objeto
|
|
426
|
+
* Função para filtrar propriedades especificas dentro de um objeto
|
|
756
427
|
*
|
|
757
428
|
* @param {object} fields objeto com propriedades
|
|
758
|
-
* @param {array} models array de string com nomes das
|
|
429
|
+
* @param {array} models array de string com nomes das propriedades que serão filtradas
|
|
759
430
|
* @returns {object} objeto com propriedades filtradas
|
|
760
431
|
*
|
|
761
432
|
* @example
|
|
@@ -1335,7 +1006,7 @@
|
|
|
1335
1006
|
const _hoisted_11$1 = { class: "ellipsis q-mt-lg qs-lh-sm text-bold text-subtitle1" };
|
|
1336
1007
|
const _hoisted_12$1 = { class: "ellipsis q-mt-xs text-caption" };
|
|
1337
1008
|
const _hoisted_13$1 = { class: "q-mt-sm" };
|
|
1338
|
-
const _hoisted_14 = { class: "q-mt-sm" };
|
|
1009
|
+
const _hoisted_14$1 = { class: "q-mt-sm" };
|
|
1339
1010
|
|
|
1340
1011
|
function render$F(_ctx, _cache, $props, $setup, $data, $options) {
|
|
1341
1012
|
const _component_q_ajax_bar = vue.resolveComponent("q-ajax-bar");
|
|
@@ -1481,7 +1152,7 @@
|
|
|
1481
1152
|
to: $props.user.to
|
|
1482
1153
|
}, null, 8 /* PROPS */, ["to"])
|
|
1483
1154
|
]),
|
|
1484
|
-
vue.createElementVNode("div", _hoisted_14, [
|
|
1155
|
+
vue.createElementVNode("div", _hoisted_14$1, [
|
|
1485
1156
|
vue.withDirectives(vue.createVNode(_component_qas_btn, {
|
|
1486
1157
|
class: "q-px-lg q-py-xs",
|
|
1487
1158
|
dense: "",
|
|
@@ -1516,8 +1187,6 @@
|
|
|
1516
1187
|
var script$E = {
|
|
1517
1188
|
name: 'QasAppMenu',
|
|
1518
1189
|
|
|
1519
|
-
mixins: [screenMixin],
|
|
1520
|
-
|
|
1521
1190
|
props: {
|
|
1522
1191
|
items: {
|
|
1523
1192
|
default: () => [],
|
|
@@ -1619,7 +1288,7 @@
|
|
|
1619
1288
|
},
|
|
1620
1289
|
|
|
1621
1290
|
beforeHide () {
|
|
1622
|
-
if (this.
|
|
1291
|
+
if (this.$qas.screen.isLarge) {
|
|
1623
1292
|
this.model = true;
|
|
1624
1293
|
this.miniMode = !this.miniMode;
|
|
1625
1294
|
}
|
|
@@ -2518,8 +2187,6 @@
|
|
|
2518
2187
|
QasActions: script$L
|
|
2519
2188
|
},
|
|
2520
2189
|
|
|
2521
|
-
mixins: [screenMixin],
|
|
2522
|
-
|
|
2523
2190
|
props: {
|
|
2524
2191
|
actionsProps: {
|
|
2525
2192
|
default: () => ({}),
|
|
@@ -2602,8 +2269,8 @@
|
|
|
2602
2269
|
|
|
2603
2270
|
style () {
|
|
2604
2271
|
return {
|
|
2605
|
-
maxWidth: this.maxWidth || (this.
|
|
2606
|
-
minWidth: this.minWidth || (this.
|
|
2272
|
+
maxWidth: this.maxWidth || (this.$qas.screen.isSmall ? '' : '600px'),
|
|
2273
|
+
minWidth: this.minWidth || (this.$qas.screen.isSmall ? '' : '400px')
|
|
2607
2274
|
}
|
|
2608
2275
|
},
|
|
2609
2276
|
|
|
@@ -2624,12 +2291,12 @@
|
|
|
2624
2291
|
this.useForm && this.$emit('validate', await this.$refs.form.validate());
|
|
2625
2292
|
},
|
|
2626
2293
|
|
|
2627
|
-
//
|
|
2294
|
+
// método para funcionar como plugin
|
|
2628
2295
|
show () {
|
|
2629
2296
|
this.$refs.dialog.show();
|
|
2630
2297
|
},
|
|
2631
2298
|
|
|
2632
|
-
//
|
|
2299
|
+
// método para funcionar como plugin
|
|
2633
2300
|
hide () {
|
|
2634
2301
|
this.$refs.dialog.hide();
|
|
2635
2302
|
},
|
|
@@ -2765,9 +2432,87 @@
|
|
|
2765
2432
|
progress: true
|
|
2766
2433
|
});
|
|
2767
2434
|
|
|
2768
|
-
var NotifySuccess = (message, caption) => {
|
|
2769
|
-
quasar.Notify?.create({ caption, message, type: 'success' });
|
|
2770
|
-
};
|
|
2435
|
+
var NotifySuccess = (message, caption) => {
|
|
2436
|
+
quasar.Notify?.create({ caption, message, type: 'success' });
|
|
2437
|
+
};
|
|
2438
|
+
|
|
2439
|
+
var Screen = () => {
|
|
2440
|
+
const screensModel = {
|
|
2441
|
+
// até 599px
|
|
2442
|
+
isSmall: () => quasar.Screen.xs,
|
|
2443
|
+
// de 600 até 1023px
|
|
2444
|
+
isMedium: () => quasar.Screen.sm,
|
|
2445
|
+
// de 600 até 1023px
|
|
2446
|
+
isLarge: () => quasar.Screen.gt.sm,
|
|
2447
|
+
// de 0 até 599px
|
|
2448
|
+
untilMedium: () => quasar.Screen.lt.sm,
|
|
2449
|
+
// de 0 ate 1023px
|
|
2450
|
+
untilLarge: () => quasar.Screen.lt.md,
|
|
2451
|
+
|
|
2452
|
+
// Plataforma
|
|
2453
|
+
isMobile: () => quasar.Platform.is.mobile || false
|
|
2454
|
+
};
|
|
2455
|
+
|
|
2456
|
+
const screens = {};
|
|
2457
|
+
|
|
2458
|
+
for (const key in screensModel) {
|
|
2459
|
+
// infelizmente esta é a única forma que conseguimos para que nossa função se tornasse reativa na view
|
|
2460
|
+
// é como o próprio quasar implementa
|
|
2461
|
+
Object.defineProperty(screens, key, {
|
|
2462
|
+
get () {
|
|
2463
|
+
return screensModel[key]()
|
|
2464
|
+
},
|
|
2465
|
+
|
|
2466
|
+
enumerable: true
|
|
2467
|
+
});
|
|
2468
|
+
}
|
|
2469
|
+
|
|
2470
|
+
return screens
|
|
2471
|
+
};
|
|
2472
|
+
|
|
2473
|
+
const history$2 = vue.reactive({ list: [] });
|
|
2474
|
+
|
|
2475
|
+
function useHistory () {
|
|
2476
|
+
const hasPreviousRoute = vue.computed(() => history$2.list.length > 1);
|
|
2477
|
+
|
|
2478
|
+
function getPreviousRoute (currentRoute) {
|
|
2479
|
+
const index = lodashEs.findLastIndex(history$2.list, item => item.name === currentRoute.name);
|
|
2480
|
+
|
|
2481
|
+
if (~index) {
|
|
2482
|
+
history$2.list.splice(index, 1);
|
|
2483
|
+
}
|
|
2484
|
+
|
|
2485
|
+
return history$2.list[history$2.list.length - 1]
|
|
2486
|
+
}
|
|
2487
|
+
|
|
2488
|
+
function addRoute (route) {
|
|
2489
|
+
const routeExistsInList = history$2.list?.[history$2.list?.length - 1]?.name === route.name;
|
|
2490
|
+
|
|
2491
|
+
if (routeExistsInList) return
|
|
2492
|
+
|
|
2493
|
+
history$2.list.push(route);
|
|
2494
|
+
}
|
|
2495
|
+
|
|
2496
|
+
function destroyRoutes (routes) {
|
|
2497
|
+
if (!history$2.list.length) return null
|
|
2498
|
+
|
|
2499
|
+
routes.forEach(route => {
|
|
2500
|
+
const index = history$2.list.findIndex(item => item.name === route.name);
|
|
2501
|
+
|
|
2502
|
+
if (~index) {
|
|
2503
|
+
history$2.list.splice(index, 1);
|
|
2504
|
+
}
|
|
2505
|
+
});
|
|
2506
|
+
}
|
|
2507
|
+
|
|
2508
|
+
return {
|
|
2509
|
+
history: history$2,
|
|
2510
|
+
hasPreviousRoute,
|
|
2511
|
+
getPreviousRoute,
|
|
2512
|
+
addRoute,
|
|
2513
|
+
destroyRoutes
|
|
2514
|
+
}
|
|
2515
|
+
}
|
|
2771
2516
|
|
|
2772
2517
|
var script$w = {
|
|
2773
2518
|
name: 'QasDelete',
|
|
@@ -2805,6 +2550,11 @@
|
|
|
2805
2550
|
|
|
2806
2551
|
deleting: {
|
|
2807
2552
|
type: Boolean
|
|
2553
|
+
},
|
|
2554
|
+
|
|
2555
|
+
useAutoDeleteRoute: {
|
|
2556
|
+
default: true,
|
|
2557
|
+
type: Boolean
|
|
2808
2558
|
}
|
|
2809
2559
|
},
|
|
2810
2560
|
|
|
@@ -2852,9 +2602,21 @@
|
|
|
2852
2602
|
this.$emit('update:deleting', true);
|
|
2853
2603
|
|
|
2854
2604
|
try {
|
|
2605
|
+
const { destroyRoutes, history } = useHistory();
|
|
2606
|
+
|
|
2855
2607
|
await this.$store.dispatch(`${this.entity}/destroy`, { id: this.id, url: this.url });
|
|
2608
|
+
|
|
2856
2609
|
NotifySuccess('Item deletado com sucesso!');
|
|
2610
|
+
|
|
2611
|
+
if (this.useAutoDeleteRoute) {
|
|
2612
|
+
// remove todas rotas que possuem o id do item excluído.
|
|
2613
|
+
const routesToBeDeleted = this.getRoutesToBeDeletedById(history.list);
|
|
2614
|
+
destroyRoutes(routesToBeDeleted);
|
|
2615
|
+
}
|
|
2616
|
+
|
|
2617
|
+
// cria um evento para notificar que o item foi excluído no "window".
|
|
2857
2618
|
this.createDeleteSuccessEvent();
|
|
2619
|
+
|
|
2858
2620
|
this.$emit('success');
|
|
2859
2621
|
} catch (error) {
|
|
2860
2622
|
NotifyError('Ops! Não foi possível deletar o item.');
|
|
@@ -2865,6 +2627,10 @@
|
|
|
2865
2627
|
}
|
|
2866
2628
|
},
|
|
2867
2629
|
|
|
2630
|
+
getRoutesToBeDeletedById (routes = []) {
|
|
2631
|
+
return routes.filter(({ params }) => params.id === this.id)
|
|
2632
|
+
},
|
|
2633
|
+
|
|
2868
2634
|
createDeleteSuccessEvent () {
|
|
2869
2635
|
const event = new CustomEvent('delete-success', {
|
|
2870
2636
|
bubbles: false,
|
|
@@ -3023,7 +2789,7 @@
|
|
|
3023
2789
|
props: {
|
|
3024
2790
|
modelValue: {
|
|
3025
2791
|
default: '',
|
|
3026
|
-
type: String
|
|
2792
|
+
type: [String, Number]
|
|
3027
2793
|
},
|
|
3028
2794
|
|
|
3029
2795
|
unmaskedValue: {
|
|
@@ -3034,11 +2800,31 @@
|
|
|
3034
2800
|
outlined: {
|
|
3035
2801
|
default: true,
|
|
3036
2802
|
type: Boolean
|
|
2803
|
+
},
|
|
2804
|
+
|
|
2805
|
+
removeErrorOnType: {
|
|
2806
|
+
type: Boolean
|
|
2807
|
+
},
|
|
2808
|
+
|
|
2809
|
+
error: {
|
|
2810
|
+
type: Boolean
|
|
2811
|
+
},
|
|
2812
|
+
|
|
2813
|
+
errorMessage: {
|
|
2814
|
+
type: String,
|
|
2815
|
+
default: ''
|
|
3037
2816
|
}
|
|
3038
2817
|
},
|
|
3039
2818
|
|
|
3040
2819
|
emits: ['update:modelValue'],
|
|
3041
2820
|
|
|
2821
|
+
data () {
|
|
2822
|
+
return {
|
|
2823
|
+
errorData: false,
|
|
2824
|
+
messageErrorData: ''
|
|
2825
|
+
}
|
|
2826
|
+
},
|
|
2827
|
+
|
|
3042
2828
|
computed: {
|
|
3043
2829
|
hasError () {
|
|
3044
2830
|
return this.inputReference.hasError
|
|
@@ -3071,6 +2857,11 @@
|
|
|
3071
2857
|
},
|
|
3072
2858
|
|
|
3073
2859
|
set (value) {
|
|
2860
|
+
if (this.removeErrorOnType && this.error) {
|
|
2861
|
+
this.errorData = false;
|
|
2862
|
+
this.errorMessageData = '';
|
|
2863
|
+
}
|
|
2864
|
+
|
|
3074
2865
|
return this.$emit('update:modelValue', value)
|
|
3075
2866
|
}
|
|
3076
2867
|
}
|
|
@@ -3083,6 +2874,22 @@
|
|
|
3083
2874
|
requestAnimationFrame(() => {
|
|
3084
2875
|
input.selectionStart = input.value ? input.value.length : '';
|
|
3085
2876
|
});
|
|
2877
|
+
},
|
|
2878
|
+
|
|
2879
|
+
error: {
|
|
2880
|
+
handler (value) {
|
|
2881
|
+
this.errorData = value;
|
|
2882
|
+
},
|
|
2883
|
+
|
|
2884
|
+
immediate: true
|
|
2885
|
+
},
|
|
2886
|
+
|
|
2887
|
+
errorMessage: {
|
|
2888
|
+
handler (value) {
|
|
2889
|
+
this.errorMessageData = value;
|
|
2890
|
+
},
|
|
2891
|
+
|
|
2892
|
+
immediate: true
|
|
3086
2893
|
}
|
|
3087
2894
|
},
|
|
3088
2895
|
|
|
@@ -3114,8 +2921,10 @@
|
|
|
3114
2921
|
ref: "input",
|
|
3115
2922
|
modelValue: $options.model,
|
|
3116
2923
|
"onUpdate:modelValue": _cache[0] || (_cache[0] = $event => (($options.model) = $event)),
|
|
3117
|
-
"bottom-slots": ""
|
|
2924
|
+
"bottom-slots": "",
|
|
2925
|
+
error: $data.errorData
|
|
3118
2926
|
}, _ctx.$attrs, {
|
|
2927
|
+
"error-message": _ctx.errorMessageData,
|
|
3119
2928
|
mask: $options.mask,
|
|
3120
2929
|
outlined: $props.outlined,
|
|
3121
2930
|
"unmasked-value": $props.unmaskedValue
|
|
@@ -3128,7 +2937,7 @@
|
|
|
3128
2937
|
])
|
|
3129
2938
|
}
|
|
3130
2939
|
})
|
|
3131
|
-
]), 1040 /* FULL_PROPS, DYNAMIC_SLOTS */, ["modelValue", "mask", "outlined", "unmasked-value"])
|
|
2940
|
+
]), 1040 /* FULL_PROPS, DYNAMIC_SLOTS */, ["modelValue", "error", "error-message", "mask", "outlined", "unmasked-value"])
|
|
3132
2941
|
]))
|
|
3133
2942
|
}
|
|
3134
2943
|
|
|
@@ -3283,6 +3092,88 @@
|
|
|
3283
3092
|
script$t.render = render$t;
|
|
3284
3093
|
script$t.__file = "src/components/numeric-input/QasNumericInput.vue";
|
|
3285
3094
|
|
|
3095
|
+
const levels = {
|
|
3096
|
+
0: {
|
|
3097
|
+
color: 'negative',
|
|
3098
|
+
label: 'Muito fraco',
|
|
3099
|
+
progress: 0.05,
|
|
3100
|
+
textClass: 'text-negative'
|
|
3101
|
+
},
|
|
3102
|
+
|
|
3103
|
+
1: {
|
|
3104
|
+
color: 'warning',
|
|
3105
|
+
label: 'Fraco',
|
|
3106
|
+
progress: 0.25,
|
|
3107
|
+
textClass: 'text-warning'
|
|
3108
|
+
},
|
|
3109
|
+
|
|
3110
|
+
2: {
|
|
3111
|
+
color: 'warning',
|
|
3112
|
+
label: 'Bom',
|
|
3113
|
+
progress: 0.5,
|
|
3114
|
+
textClass: 'text-warning'
|
|
3115
|
+
},
|
|
3116
|
+
|
|
3117
|
+
3: {
|
|
3118
|
+
color: 'positive',
|
|
3119
|
+
label: 'Forte',
|
|
3120
|
+
progress: 0.75,
|
|
3121
|
+
textClass: 'text-positive'
|
|
3122
|
+
},
|
|
3123
|
+
|
|
3124
|
+
4: {
|
|
3125
|
+
color: 'positive',
|
|
3126
|
+
label: 'Muito forte',
|
|
3127
|
+
progress: 1,
|
|
3128
|
+
textClass: 'text-positive'
|
|
3129
|
+
}
|
|
3130
|
+
};
|
|
3131
|
+
|
|
3132
|
+
var passwordMixin = {
|
|
3133
|
+
props: {
|
|
3134
|
+
levels: {
|
|
3135
|
+
default: () => levels,
|
|
3136
|
+
type: Object
|
|
3137
|
+
},
|
|
3138
|
+
|
|
3139
|
+
// https://developer.mozilla.org/en-US/docs/Web/HTML/Attributes/minlength
|
|
3140
|
+
minlength: {
|
|
3141
|
+
default: 8,
|
|
3142
|
+
type: [Number, String]
|
|
3143
|
+
},
|
|
3144
|
+
|
|
3145
|
+
specials: {
|
|
3146
|
+
default: /[!@#$%^&*()_+\-=[\]{}|;:'",<.>/?`~]/g,
|
|
3147
|
+
type: RegExp
|
|
3148
|
+
},
|
|
3149
|
+
|
|
3150
|
+
trackColor: {
|
|
3151
|
+
default: 'blue-grey-1',
|
|
3152
|
+
type: String
|
|
3153
|
+
},
|
|
3154
|
+
|
|
3155
|
+
useLowercase: {
|
|
3156
|
+
default: true,
|
|
3157
|
+
type: Boolean
|
|
3158
|
+
},
|
|
3159
|
+
|
|
3160
|
+
useNumbers: {
|
|
3161
|
+
default: true,
|
|
3162
|
+
type: Boolean
|
|
3163
|
+
},
|
|
3164
|
+
|
|
3165
|
+
useSpecial: {
|
|
3166
|
+
default: true,
|
|
3167
|
+
type: Boolean
|
|
3168
|
+
},
|
|
3169
|
+
|
|
3170
|
+
useUppercase: {
|
|
3171
|
+
default: true,
|
|
3172
|
+
type: Boolean
|
|
3173
|
+
}
|
|
3174
|
+
}
|
|
3175
|
+
};
|
|
3176
|
+
|
|
3286
3177
|
var script$s = {
|
|
3287
3178
|
name: 'QasPasswordStrengthChecker',
|
|
3288
3179
|
|
|
@@ -3387,9 +3278,8 @@
|
|
|
3387
3278
|
mixins: [passwordMixin],
|
|
3388
3279
|
|
|
3389
3280
|
props: {
|
|
3390
|
-
|
|
3391
|
-
type: Boolean
|
|
3392
|
-
default: true
|
|
3281
|
+
hideStrengthChecker: {
|
|
3282
|
+
type: Boolean
|
|
3393
3283
|
},
|
|
3394
3284
|
|
|
3395
3285
|
iconColor: {
|
|
@@ -3407,7 +3297,6 @@
|
|
|
3407
3297
|
|
|
3408
3298
|
data () {
|
|
3409
3299
|
return {
|
|
3410
|
-
key: 'error',
|
|
3411
3300
|
toggleType: true
|
|
3412
3301
|
}
|
|
3413
3302
|
},
|
|
@@ -3437,15 +3326,6 @@
|
|
|
3437
3326
|
}
|
|
3438
3327
|
},
|
|
3439
3328
|
|
|
3440
|
-
watch: {
|
|
3441
|
-
modelValue () {
|
|
3442
|
-
if (this.$attrs.error) {
|
|
3443
|
-
this.$attrs.error = false;
|
|
3444
|
-
this.$attrs.errorMessage = '';
|
|
3445
|
-
}
|
|
3446
|
-
}
|
|
3447
|
-
},
|
|
3448
|
-
|
|
3449
3329
|
methods: {
|
|
3450
3330
|
toggle () {
|
|
3451
3331
|
this.toggleType = !this.toggleType;
|
|
@@ -3458,39 +3338,43 @@
|
|
|
3458
3338
|
const _component_qas_password_strength_checker = vue.resolveComponent("qas-password-strength-checker");
|
|
3459
3339
|
const _component_qas_input = vue.resolveComponent("qas-input");
|
|
3460
3340
|
|
|
3461
|
-
return (vue.openBlock(), vue.
|
|
3462
|
-
|
|
3463
|
-
|
|
3464
|
-
|
|
3465
|
-
|
|
3466
|
-
|
|
3467
|
-
|
|
3468
|
-
|
|
3469
|
-
|
|
3470
|
-
|
|
3471
|
-
|
|
3472
|
-
|
|
3473
|
-
|
|
3474
|
-
|
|
3475
|
-
|
|
3476
|
-
|
|
3477
|
-
|
|
3478
|
-
|
|
3479
|
-
|
|
3480
|
-
|
|
3481
|
-
|
|
3482
|
-
|
|
3483
|
-
|
|
3484
|
-
|
|
3485
|
-
($props.useStrengthChecker)
|
|
3486
|
-
? {
|
|
3487
|
-
name: "hint",
|
|
3488
|
-
fn: vue.withCtx(() => [
|
|
3489
|
-
vue.createVNode(_component_qas_password_strength_checker, vue.mergeProps($options.strengthCheckerProps, { password: $options.model }), null, 16 /* FULL_PROPS */, ["password"])
|
|
3341
|
+
return (vue.openBlock(), vue.createElementBlock("div", null, [
|
|
3342
|
+
vue.createVNode(_component_qas_input, vue.mergeProps({
|
|
3343
|
+
modelValue: $options.model,
|
|
3344
|
+
"onUpdate:modelValue": _cache[0] || (_cache[0] = $event => (($options.model) = $event)),
|
|
3345
|
+
"bottom-slots": ""
|
|
3346
|
+
}, _ctx.$attrs, {
|
|
3347
|
+
"remove-error-on-type": "",
|
|
3348
|
+
type: $options.type
|
|
3349
|
+
}), vue.createSlots({
|
|
3350
|
+
append: vue.withCtx(() => [
|
|
3351
|
+
vue.createVNode(_component_q_icon, {
|
|
3352
|
+
class: "cursor-pointer",
|
|
3353
|
+
color: $props.iconColor,
|
|
3354
|
+
name: $options.icon,
|
|
3355
|
+
onClick: $options.toggle
|
|
3356
|
+
}, null, 8 /* PROPS */, ["color", "name", "onClick"])
|
|
3357
|
+
]),
|
|
3358
|
+
_: 2 /* DYNAMIC */
|
|
3359
|
+
}, [
|
|
3360
|
+
vue.renderList(_ctx.$slots, (_, name) => {
|
|
3361
|
+
return {
|
|
3362
|
+
name: name,
|
|
3363
|
+
fn: vue.withCtx((context) => [
|
|
3364
|
+
vue.renderSlot(_ctx.$slots, name, vue.normalizeProps(vue.guardReactiveProps(context || {})))
|
|
3490
3365
|
])
|
|
3491
3366
|
}
|
|
3492
|
-
|
|
3493
|
-
|
|
3367
|
+
}),
|
|
3368
|
+
(!$props.hideStrengthChecker)
|
|
3369
|
+
? {
|
|
3370
|
+
name: "hint",
|
|
3371
|
+
fn: vue.withCtx(() => [
|
|
3372
|
+
vue.createVNode(_component_qas_password_strength_checker, vue.mergeProps($options.strengthCheckerProps, { password: $options.model }), null, 16 /* FULL_PROPS */, ["password"])
|
|
3373
|
+
])
|
|
3374
|
+
}
|
|
3375
|
+
: undefined
|
|
3376
|
+
]), 1040 /* FULL_PROPS, DYNAMIC_SLOTS */, ["modelValue", "type"])
|
|
3377
|
+
]))
|
|
3494
3378
|
}
|
|
3495
3379
|
|
|
3496
3380
|
script$r.render = render$r;
|
|
@@ -3689,7 +3573,7 @@
|
|
|
3689
3573
|
this.isFetching = true;
|
|
3690
3574
|
|
|
3691
3575
|
try {
|
|
3692
|
-
const { data } = await
|
|
3576
|
+
const { data } = await this.$axios.post('/upload-credentials/', {
|
|
3693
3577
|
entity: this.entity,
|
|
3694
3578
|
filename
|
|
3695
3579
|
});
|
|
@@ -4167,6 +4051,11 @@
|
|
|
4167
4051
|
},
|
|
4168
4052
|
|
|
4169
4053
|
props: {
|
|
4054
|
+
dialogProps: {
|
|
4055
|
+
type: Object,
|
|
4056
|
+
default: () => ({})
|
|
4057
|
+
},
|
|
4058
|
+
|
|
4170
4059
|
uploadLabel: {
|
|
4171
4060
|
default: '',
|
|
4172
4061
|
type: String
|
|
@@ -4215,6 +4104,32 @@
|
|
|
4215
4104
|
|
|
4216
4105
|
headerClass () {
|
|
4217
4106
|
return `q-pa-${this.readonly ? 'md' : 'sm'}`
|
|
4107
|
+
},
|
|
4108
|
+
|
|
4109
|
+
defaultDialogProps () {
|
|
4110
|
+
return {
|
|
4111
|
+
maxWidth: '620px',
|
|
4112
|
+
...this.dialogProps
|
|
4113
|
+
}
|
|
4114
|
+
},
|
|
4115
|
+
|
|
4116
|
+
signaturePadWidth () {
|
|
4117
|
+
const sizes = {
|
|
4118
|
+
[this.$qas.screen.isSmall]: { width: '100%' },
|
|
4119
|
+
[this.$qas.screen.isMedium]: { width: '570px' },
|
|
4120
|
+
[this.$qas.screen.isLarge]: { width: '350px' }
|
|
4121
|
+
};
|
|
4122
|
+
return sizes.true
|
|
4123
|
+
},
|
|
4124
|
+
|
|
4125
|
+
signaturePadHeight () {
|
|
4126
|
+
const sizes = {
|
|
4127
|
+
[this.$qas.screen.isSmall]: '250',
|
|
4128
|
+
[this.$qas.screen.isMedium]: '400',
|
|
4129
|
+
[this.$qas.screen.isLarge]: '250'
|
|
4130
|
+
};
|
|
4131
|
+
|
|
4132
|
+
return sizes.true
|
|
4218
4133
|
}
|
|
4219
4134
|
},
|
|
4220
4135
|
|
|
@@ -4314,20 +4229,24 @@
|
|
|
4314
4229
|
]),
|
|
4315
4230
|
_: 1 /* STABLE */
|
|
4316
4231
|
}, 16 /* FULL_PROPS */, ["modelValue", "label", "readonly"]),
|
|
4317
|
-
vue.createVNode(_component_qas_dialog, {
|
|
4232
|
+
vue.createVNode(_component_qas_dialog, vue.mergeProps({
|
|
4318
4233
|
modelValue: $data.isOpenedDialog,
|
|
4319
4234
|
"onUpdate:modelValue": _cache[3] || (_cache[3] = $event => (($data.isOpenedDialog) = $event))
|
|
4320
|
-
}, {
|
|
4235
|
+
}, $options.defaultDialogProps), {
|
|
4321
4236
|
header: vue.withCtx(() => [
|
|
4322
4237
|
_hoisted_3$8
|
|
4323
4238
|
]),
|
|
4324
4239
|
description: vue.withCtx(() => [
|
|
4325
|
-
vue.
|
|
4326
|
-
|
|
4327
|
-
|
|
4328
|
-
|
|
4329
|
-
|
|
4330
|
-
|
|
4240
|
+
vue.createElementVNode("div", {
|
|
4241
|
+
style: vue.normalizeStyle($options.signaturePadWidth)
|
|
4242
|
+
}, [
|
|
4243
|
+
vue.createVNode(_component_qas_signature_pad, {
|
|
4244
|
+
ref: "signaturePadModal",
|
|
4245
|
+
empty: $data.isEmpty,
|
|
4246
|
+
"onUpdate:empty": _cache[2] || (_cache[2] = $event => (($data.isEmpty) = $event)),
|
|
4247
|
+
height: $options.signaturePadHeight
|
|
4248
|
+
}, null, 8 /* PROPS */, ["empty", "height"])
|
|
4249
|
+
], 4 /* STYLE */)
|
|
4331
4250
|
]),
|
|
4332
4251
|
actions: vue.withCtx(() => [
|
|
4333
4252
|
vue.createVNode(_component_q_btn, {
|
|
@@ -4348,7 +4267,7 @@
|
|
|
4348
4267
|
}, null, 8 /* PROPS */, ["onClick"])
|
|
4349
4268
|
]),
|
|
4350
4269
|
_: 1 /* STABLE */
|
|
4351
|
-
},
|
|
4270
|
+
}, 16 /* FULL_PROPS */, ["modelValue"])
|
|
4352
4271
|
]))
|
|
4353
4272
|
}
|
|
4354
4273
|
|
|
@@ -4412,7 +4331,6 @@
|
|
|
4412
4331
|
prefix,
|
|
4413
4332
|
type,
|
|
4414
4333
|
mask,
|
|
4415
|
-
pattern,
|
|
4416
4334
|
maxFiles,
|
|
4417
4335
|
searchable,
|
|
4418
4336
|
gmt
|
|
@@ -4463,7 +4381,7 @@
|
|
|
4463
4381
|
number: { is: 'qas-input', type: 'number', ...input },
|
|
4464
4382
|
hidden: { is: 'input', name, type },
|
|
4465
4383
|
email: { is: 'qas-input', type, ...input },
|
|
4466
|
-
password: { is: 'qas-password-input',
|
|
4384
|
+
password: { is: 'qas-password-input', ...input },
|
|
4467
4385
|
|
|
4468
4386
|
decimal: { ...numericInput, mode: 'decimal' },
|
|
4469
4387
|
money: { ...numericInput, mode: 'money' },
|
|
@@ -4565,6 +4483,15 @@
|
|
|
4565
4483
|
script$n.render = render$n;
|
|
4566
4484
|
script$n.__file = "src/components/field/QasField.vue";
|
|
4567
4485
|
|
|
4486
|
+
var contextMixin = {
|
|
4487
|
+
computed: {
|
|
4488
|
+
mx_context () {
|
|
4489
|
+
const { limit, ordering, page, search, ...filters } = this.$route.query;
|
|
4490
|
+
return { filters, limit, ordering, page: page ? parseInt(page) : 1, search }
|
|
4491
|
+
}
|
|
4492
|
+
}
|
|
4493
|
+
};
|
|
4494
|
+
|
|
4568
4495
|
var script$m = {
|
|
4569
4496
|
name: 'QasFilters',
|
|
4570
4497
|
|
|
@@ -4608,6 +4535,10 @@
|
|
|
4608
4535
|
url: {
|
|
4609
4536
|
default: '',
|
|
4610
4537
|
type: String
|
|
4538
|
+
},
|
|
4539
|
+
|
|
4540
|
+
forceRefetch: {
|
|
4541
|
+
type: Boolean
|
|
4611
4542
|
}
|
|
4612
4543
|
},
|
|
4613
4544
|
|
|
@@ -4737,7 +4668,7 @@
|
|
|
4737
4668
|
},
|
|
4738
4669
|
|
|
4739
4670
|
async fetchFilters () {
|
|
4740
|
-
if (this.hasFields || !this.useFilterButton) {
|
|
4671
|
+
if (!this.forceRefetch && (this.hasFields || !this.useFilterButton)) {
|
|
4741
4672
|
return null
|
|
4742
4673
|
}
|
|
4743
4674
|
|
|
@@ -4903,7 +4834,7 @@
|
|
|
4903
4834
|
label: $options.filterButtonLabel
|
|
4904
4835
|
}, {
|
|
4905
4836
|
default: vue.withCtx(() => [
|
|
4906
|
-
vue.createVNode(_component_q_menu,
|
|
4837
|
+
vue.createVNode(_component_q_menu, null, {
|
|
4907
4838
|
default: vue.withCtx(() => [
|
|
4908
4839
|
($data.isFetching)
|
|
4909
4840
|
? (vue.openBlock(), vue.createElementBlock("div", _hoisted_4$6, [
|
|
@@ -4957,7 +4888,7 @@
|
|
|
4957
4888
|
}))
|
|
4958
4889
|
]),
|
|
4959
4890
|
_: 1 /* STABLE */
|
|
4960
|
-
}
|
|
4891
|
+
})
|
|
4961
4892
|
]),
|
|
4962
4893
|
_: 1 /* STABLE */
|
|
4963
4894
|
}, 8 /* PROPS */, ["color", "label"]))
|
|
@@ -4995,8 +4926,95 @@
|
|
|
4995
4926
|
]))
|
|
4996
4927
|
}
|
|
4997
4928
|
|
|
4998
|
-
script$m.render = render$m;
|
|
4999
|
-
script$m.__file = "src/components/filters/QasFilters.vue";
|
|
4929
|
+
script$m.render = render$m;
|
|
4930
|
+
script$m.__file = "src/components/filters/QasFilters.vue";
|
|
4931
|
+
|
|
4932
|
+
const irregularClasses = ['col', 'col-auto', 'fit'];
|
|
4933
|
+
|
|
4934
|
+
var generatorMixin = {
|
|
4935
|
+
props: {
|
|
4936
|
+
columns: {
|
|
4937
|
+
default: () => [],
|
|
4938
|
+
type: [Array, String, Object]
|
|
4939
|
+
},
|
|
4940
|
+
|
|
4941
|
+
fields: {
|
|
4942
|
+
default: () => ({}),
|
|
4943
|
+
type: Object
|
|
4944
|
+
},
|
|
4945
|
+
|
|
4946
|
+
gutter: {
|
|
4947
|
+
default: 'md',
|
|
4948
|
+
type: [String, Boolean],
|
|
4949
|
+
validator: value => ['xs', 'sm', 'md', 'lg', 'xl'].includes(value)
|
|
4950
|
+
}
|
|
4951
|
+
},
|
|
4952
|
+
|
|
4953
|
+
computed: {
|
|
4954
|
+
mx_classes () {
|
|
4955
|
+
const classes = ['row'];
|
|
4956
|
+
|
|
4957
|
+
if (this.gutter) {
|
|
4958
|
+
classes.push(`q-col-gutter-${this.gutter}`);
|
|
4959
|
+
}
|
|
4960
|
+
|
|
4961
|
+
return classes
|
|
4962
|
+
}
|
|
4963
|
+
},
|
|
4964
|
+
|
|
4965
|
+
methods: {
|
|
4966
|
+
mx_getBreakpoint (columns) {
|
|
4967
|
+
const classes = [];
|
|
4968
|
+
const profiles = { col: 'col', xs: 'col-xs', sm: 'col-sm', md: 'col-md', lg: 'col-lg', xl: 'col-xl' };
|
|
4969
|
+
const { fieldProps, classes: renamedClasses, ...formattedColumns } = columns || {};
|
|
4970
|
+
|
|
4971
|
+
for (const key in formattedColumns) {
|
|
4972
|
+
const value = formattedColumns[key];
|
|
4973
|
+
classes.push(irregularClasses.includes(value) ? value : `${profiles[key]}-${value}`);
|
|
4974
|
+
}
|
|
4975
|
+
|
|
4976
|
+
return [...classes, renamedClasses]
|
|
4977
|
+
},
|
|
4978
|
+
|
|
4979
|
+
mx_getFieldClass (index, isGridGenerator) {
|
|
4980
|
+
if (typeof this.columns === 'string') {
|
|
4981
|
+
return irregularClasses.includes(this.columns) ? this.columns : `col-${this.columns}`
|
|
4982
|
+
}
|
|
4983
|
+
|
|
4984
|
+
return Array.isArray(this.columns)
|
|
4985
|
+
? this.mx_handleColumnsByIndex(index, isGridGenerator)
|
|
4986
|
+
: this.mx_handleColumnsByField(index, isGridGenerator)
|
|
4987
|
+
},
|
|
4988
|
+
|
|
4989
|
+
mx_handleColumnsByField (index, isGridGenerator) {
|
|
4990
|
+
if (!this.columns[index]) {
|
|
4991
|
+
return this.mx_setDefaultColumnClass(isGridGenerator)
|
|
4992
|
+
}
|
|
4993
|
+
|
|
4994
|
+
return this.mx_getBreakpoint(this.columns[index])
|
|
4995
|
+
},
|
|
4996
|
+
|
|
4997
|
+
mx_handleColumnsByIndex (index, isGridGenerator) {
|
|
4998
|
+
const fields = isGridGenerator ? this.fields : this.groupedFields.visible;
|
|
4999
|
+
|
|
5000
|
+
if (!Array.isArray(fields)) {
|
|
5001
|
+
index = Object.keys(fields).findIndex(field => field === index);
|
|
5002
|
+
}
|
|
5003
|
+
|
|
5004
|
+
const length = this.columns.length;
|
|
5005
|
+
|
|
5006
|
+
if (!length) {
|
|
5007
|
+
return this.mx_setDefaultColumnClass(isGridGenerator)
|
|
5008
|
+
}
|
|
5009
|
+
|
|
5010
|
+
return this.mx_getBreakpoint(this.columns[index])
|
|
5011
|
+
},
|
|
5012
|
+
|
|
5013
|
+
mx_setDefaultColumnClass (isGridGenerator) {
|
|
5014
|
+
return isGridGenerator ? 'col-6 col-xs-12 col-sm-4' : 'col-6'
|
|
5015
|
+
}
|
|
5016
|
+
}
|
|
5017
|
+
};
|
|
5000
5018
|
|
|
5001
5019
|
var script$l = {
|
|
5002
5020
|
name: 'QasFormGenerator',
|
|
@@ -5105,27 +5123,123 @@
|
|
|
5105
5123
|
script$l.render = render$l;
|
|
5106
5124
|
script$l.__file = "src/components/form-generator/QasFormGenerator.vue";
|
|
5107
5125
|
|
|
5108
|
-
|
|
5126
|
+
var viewMixin = {
|
|
5127
|
+
props: {
|
|
5128
|
+
dialog: {
|
|
5129
|
+
type: Boolean
|
|
5130
|
+
},
|
|
5109
5131
|
|
|
5110
|
-
|
|
5111
|
-
|
|
5132
|
+
entity: {
|
|
5133
|
+
required: true,
|
|
5134
|
+
type: String
|
|
5135
|
+
},
|
|
5112
5136
|
|
|
5113
|
-
|
|
5114
|
-
|
|
5115
|
-
|
|
5137
|
+
url: {
|
|
5138
|
+
default: '',
|
|
5139
|
+
type: String
|
|
5140
|
+
},
|
|
5116
5141
|
|
|
5117
|
-
|
|
5118
|
-
|
|
5119
|
-
|
|
5142
|
+
fields: {
|
|
5143
|
+
default: () => ({}),
|
|
5144
|
+
type: Object
|
|
5145
|
+
},
|
|
5120
5146
|
|
|
5121
|
-
|
|
5122
|
-
|
|
5147
|
+
errors: {
|
|
5148
|
+
default: () => ({}),
|
|
5149
|
+
type: Object
|
|
5150
|
+
},
|
|
5123
5151
|
|
|
5124
|
-
|
|
5152
|
+
metadata: {
|
|
5153
|
+
default: () => ({}),
|
|
5154
|
+
type: Object
|
|
5155
|
+
},
|
|
5125
5156
|
|
|
5126
|
-
|
|
5127
|
-
|
|
5128
|
-
|
|
5157
|
+
fetching: {
|
|
5158
|
+
type: Boolean
|
|
5159
|
+
}
|
|
5160
|
+
},
|
|
5161
|
+
|
|
5162
|
+
emits: [
|
|
5163
|
+
'update:fields',
|
|
5164
|
+
'update:errors',
|
|
5165
|
+
'update:metadata',
|
|
5166
|
+
'update:fetching'
|
|
5167
|
+
],
|
|
5168
|
+
|
|
5169
|
+
data () {
|
|
5170
|
+
return {
|
|
5171
|
+
mx_errors: {},
|
|
5172
|
+
mx_fields: {},
|
|
5173
|
+
mx_metadata: {},
|
|
5174
|
+
|
|
5175
|
+
mx_isFetching: false
|
|
5176
|
+
}
|
|
5177
|
+
},
|
|
5178
|
+
|
|
5179
|
+
watch: {
|
|
5180
|
+
mx_isFetching (value) {
|
|
5181
|
+
this.$emit('update:fetching', value);
|
|
5182
|
+
}
|
|
5183
|
+
},
|
|
5184
|
+
|
|
5185
|
+
computed: {
|
|
5186
|
+
mx_componentTag () {
|
|
5187
|
+
return this.dialog ? 'div' : 'q-page'
|
|
5188
|
+
},
|
|
5189
|
+
|
|
5190
|
+
mx_componentClass () {
|
|
5191
|
+
return !this.dialog && 'container spaced'
|
|
5192
|
+
},
|
|
5193
|
+
|
|
5194
|
+
mx_hasFooterSlot () {
|
|
5195
|
+
return !!(this.$slots.footer)
|
|
5196
|
+
},
|
|
5197
|
+
|
|
5198
|
+
mx_hasHeaderSlot () {
|
|
5199
|
+
return !!(this.$slots.header)
|
|
5200
|
+
}
|
|
5201
|
+
},
|
|
5202
|
+
|
|
5203
|
+
methods: {
|
|
5204
|
+
mx_fetchError (error) {
|
|
5205
|
+
const { response } = error;
|
|
5206
|
+
const exception = response?.data?.exception || error.message;
|
|
5207
|
+
|
|
5208
|
+
this.$qas.error('Ops! Erro ao obter os dados.', exception);
|
|
5209
|
+
|
|
5210
|
+
const status = response?.status;
|
|
5211
|
+
const redirect = ({ 403: 'Forbidden', 404: 'NotFound' })[status];
|
|
5212
|
+
|
|
5213
|
+
if (redirect) {
|
|
5214
|
+
this.$router.replace({ name: redirect });
|
|
5215
|
+
}
|
|
5216
|
+
},
|
|
5217
|
+
|
|
5218
|
+
mx_setErrors (errors = {}) {
|
|
5219
|
+
this.mx_errors = vue.markRaw(errors);
|
|
5220
|
+
},
|
|
5221
|
+
|
|
5222
|
+
mx_setFields (fields = {}) {
|
|
5223
|
+
for (const field in fields) {
|
|
5224
|
+
fields[field].name = humps.camelize(fields[field].name);
|
|
5225
|
+
}
|
|
5226
|
+
|
|
5227
|
+
this.mx_fields = vue.markRaw(fields);
|
|
5228
|
+
},
|
|
5229
|
+
|
|
5230
|
+
mx_setMetadata (metadata = {}) {
|
|
5231
|
+
this.mx_metadata = vue.markRaw(metadata);
|
|
5232
|
+
},
|
|
5233
|
+
|
|
5234
|
+
mx_updateModels (models) {
|
|
5235
|
+
for (const key in models) {
|
|
5236
|
+
if (!models[key]) continue
|
|
5237
|
+
|
|
5238
|
+
this.$emit(`update:${key}`, models[key]);
|
|
5239
|
+
}
|
|
5240
|
+
}
|
|
5241
|
+
}
|
|
5242
|
+
};
|
|
5129
5243
|
|
|
5130
5244
|
var script$k = {
|
|
5131
5245
|
name: 'QasFormView',
|
|
@@ -5135,7 +5249,7 @@
|
|
|
5135
5249
|
QasDialog: script$x
|
|
5136
5250
|
},
|
|
5137
5251
|
|
|
5138
|
-
mixins: [viewMixin
|
|
5252
|
+
mixins: [viewMixin],
|
|
5139
5253
|
|
|
5140
5254
|
props: {
|
|
5141
5255
|
cancelButton: {
|
|
@@ -5145,7 +5259,7 @@
|
|
|
5145
5259
|
|
|
5146
5260
|
cancelRoute: {
|
|
5147
5261
|
default: '',
|
|
5148
|
-
type: [Boolean, Object, String]
|
|
5262
|
+
type: [Boolean, Object, String, Function]
|
|
5149
5263
|
},
|
|
5150
5264
|
|
|
5151
5265
|
customId: {
|
|
@@ -5229,7 +5343,7 @@
|
|
|
5229
5343
|
|
|
5230
5344
|
computed: {
|
|
5231
5345
|
cancelButtonClass () {
|
|
5232
|
-
return this.
|
|
5346
|
+
return this.$qas.screen.isSmall && 'order-last'
|
|
5233
5347
|
},
|
|
5234
5348
|
|
|
5235
5349
|
fetchURL () {
|
|
@@ -5257,17 +5371,13 @@
|
|
|
5257
5371
|
},
|
|
5258
5372
|
|
|
5259
5373
|
saveButtonClass () {
|
|
5260
|
-
return this.
|
|
5374
|
+
return this.$qas.screen.isSmall && 'order-first'
|
|
5261
5375
|
},
|
|
5262
5376
|
|
|
5263
5377
|
isCancelButtonDisabled () {
|
|
5264
5378
|
return this.disable || this.isSubmitting
|
|
5265
5379
|
},
|
|
5266
5380
|
|
|
5267
|
-
history () {
|
|
5268
|
-
return history$1.list
|
|
5269
|
-
},
|
|
5270
|
-
|
|
5271
5381
|
fieldsNameWithDefaultValue () {
|
|
5272
5382
|
return Object.keys(this.fields).filter(field => 'default' in this.fields[field])
|
|
5273
5383
|
}
|
|
@@ -5336,7 +5446,7 @@
|
|
|
5336
5446
|
this.mx_updateModels({
|
|
5337
5447
|
errors: errors,
|
|
5338
5448
|
fields: this.mx_fields,
|
|
5339
|
-
metadata
|
|
5449
|
+
metadata
|
|
5340
5450
|
});
|
|
5341
5451
|
|
|
5342
5452
|
if (result) {
|
|
@@ -5365,9 +5475,11 @@
|
|
|
5365
5475
|
},
|
|
5366
5476
|
|
|
5367
5477
|
handleCancelRoute () {
|
|
5368
|
-
|
|
5478
|
+
if (typeof this.cancelRoute === 'function') {
|
|
5479
|
+
return this.cancelRoute()
|
|
5480
|
+
}
|
|
5369
5481
|
|
|
5370
|
-
if (this.cancelRoute &&
|
|
5482
|
+
if (this.cancelRoute && ['string', 'object'].includes(typeof this.cancelRoute)) {
|
|
5371
5483
|
return this.$router.push(this.cancelRoute)
|
|
5372
5484
|
}
|
|
5373
5485
|
|
|
@@ -5380,6 +5492,8 @@
|
|
|
5380
5492
|
handleDialog (next) {
|
|
5381
5493
|
this.openDialog();
|
|
5382
5494
|
|
|
5495
|
+
const { addRoute } = useHistory();
|
|
5496
|
+
|
|
5383
5497
|
this.defaultDialogProps.ok.onClick = () => addRoute(this.$route);
|
|
5384
5498
|
this.defaultDialogProps.cancel.onClick = next;
|
|
5385
5499
|
},
|
|
@@ -5462,7 +5576,9 @@
|
|
|
5462
5576
|
const _component_q_inner_loading = vue.resolveComponent("q-inner-loading");
|
|
5463
5577
|
const _directive_close_popup = vue.resolveDirective("close-popup");
|
|
5464
5578
|
|
|
5465
|
-
return (vue.openBlock(), vue.createBlock(vue.resolveDynamicComponent(_ctx.mx_componentTag),
|
|
5579
|
+
return (vue.openBlock(), vue.createBlock(vue.resolveDynamicComponent(_ctx.mx_componentTag), {
|
|
5580
|
+
class: vue.normalizeClass(_ctx.mx_componentClass)
|
|
5581
|
+
}, {
|
|
5466
5582
|
default: vue.withCtx(() => [
|
|
5467
5583
|
(_ctx.mx_hasHeaderSlot)
|
|
5468
5584
|
? (vue.openBlock(), vue.createElementBlock("header", _hoisted_1$d, [
|
|
@@ -5534,7 +5650,7 @@
|
|
|
5534
5650
|
}, 8 /* PROPS */, ["showing"])
|
|
5535
5651
|
]),
|
|
5536
5652
|
_: 3 /* FORWARDED */
|
|
5537
|
-
}))
|
|
5653
|
+
}, 8 /* PROPS */, ["class"]))
|
|
5538
5654
|
}
|
|
5539
5655
|
|
|
5540
5656
|
script$k.render = render$k;
|
|
@@ -5543,8 +5659,6 @@
|
|
|
5543
5659
|
var script$j = {
|
|
5544
5660
|
name: 'QasGallery',
|
|
5545
5661
|
|
|
5546
|
-
mixins: [screenMixin],
|
|
5547
|
-
|
|
5548
5662
|
props: {
|
|
5549
5663
|
carouselNextIcon: {
|
|
5550
5664
|
type: String,
|
|
@@ -5601,13 +5715,13 @@
|
|
|
5601
5715
|
return this.height || 'auto'
|
|
5602
5716
|
}
|
|
5603
5717
|
|
|
5604
|
-
return this.
|
|
5718
|
+
return this.$qas.screen.isSmall ? '90px' : '120px'
|
|
5605
5719
|
},
|
|
5606
5720
|
|
|
5607
5721
|
galleryColumnsClasses () {
|
|
5608
5722
|
if (this.isSingleImage) return 'col-12'
|
|
5609
5723
|
|
|
5610
|
-
return this.
|
|
5724
|
+
return this.$qas.screen.isSmall ? 'col-6' : 'col-2'
|
|
5611
5725
|
},
|
|
5612
5726
|
|
|
5613
5727
|
hideShowMore () {
|
|
@@ -5742,9 +5856,9 @@
|
|
|
5742
5856
|
modelValue: $data.imageIndex,
|
|
5743
5857
|
"onUpdate:modelValue": _cache[0] || (_cache[0] = $event => (($data.imageIndex) = $event)),
|
|
5744
5858
|
animated: "",
|
|
5745
|
-
arrows: !_ctx.
|
|
5859
|
+
arrows: !_ctx.$qas.screen.isSmall,
|
|
5746
5860
|
"control-text-color": "primary",
|
|
5747
|
-
fullscreen: _ctx.
|
|
5861
|
+
fullscreen: _ctx.$qas.screen.isSmall,
|
|
5748
5862
|
height: $options.carouselImageHeight,
|
|
5749
5863
|
"next-icon": $props.carouselNextIcon,
|
|
5750
5864
|
"prev-icon": $props.carouselPreviousIcon,
|
|
@@ -5760,7 +5874,7 @@
|
|
|
5760
5874
|
name: index
|
|
5761
5875
|
}, {
|
|
5762
5876
|
default: vue.withCtx(() => [
|
|
5763
|
-
(_ctx.
|
|
5877
|
+
(_ctx.$qas.screen.isSmall)
|
|
5764
5878
|
? (vue.openBlock(), vue.createElementBlock("div", _hoisted_4$5, [
|
|
5765
5879
|
vue.createVNode(_component_qas_btn, {
|
|
5766
5880
|
dense: "",
|
|
@@ -6524,7 +6638,10 @@
|
|
|
6524
6638
|
QasBtn: script$K,
|
|
6525
6639
|
QasFormGenerator: script$l,
|
|
6526
6640
|
QasInput: script$u,
|
|
6527
|
-
QasLabel: script$h
|
|
6641
|
+
QasLabel: script$h,
|
|
6642
|
+
|
|
6643
|
+
// vue
|
|
6644
|
+
TransitionGroup: vue.TransitionGroup
|
|
6528
6645
|
},
|
|
6529
6646
|
|
|
6530
6647
|
props: {
|
|
@@ -6688,6 +6805,16 @@
|
|
|
6688
6805
|
|
|
6689
6806
|
componentTag () {
|
|
6690
6807
|
return this.useAnimation ? 'transition-group' : 'div'
|
|
6808
|
+
},
|
|
6809
|
+
|
|
6810
|
+
componentProps () {
|
|
6811
|
+
if (!this.useAnimation) return {}
|
|
6812
|
+
|
|
6813
|
+
return {
|
|
6814
|
+
tag: 'div',
|
|
6815
|
+
enterActiveClass: 'animated slideInDown',
|
|
6816
|
+
leaveActiveClass: 'animated slideOutUp'
|
|
6817
|
+
}
|
|
6691
6818
|
}
|
|
6692
6819
|
},
|
|
6693
6820
|
|
|
@@ -6772,23 +6899,24 @@
|
|
|
6772
6899
|
|
|
6773
6900
|
const _hoisted_1$8 = ["id"];
|
|
6774
6901
|
const _hoisted_2$5 = { class: "text-left" };
|
|
6775
|
-
const _hoisted_3$3 =
|
|
6776
|
-
const _hoisted_4$3 =
|
|
6777
|
-
const _hoisted_5$2 = {
|
|
6902
|
+
const _hoisted_3$3 = { ref: "inputContent" };
|
|
6903
|
+
const _hoisted_4$3 = ["id"];
|
|
6904
|
+
const _hoisted_5$2 = { class: "flex items-center justify-between q-py-xs" };
|
|
6905
|
+
const _hoisted_6 = {
|
|
6778
6906
|
key: 1,
|
|
6779
6907
|
class: "q-gutter-x-sm"
|
|
6780
6908
|
};
|
|
6781
|
-
const
|
|
6909
|
+
const _hoisted_7 = {
|
|
6782
6910
|
key: 0,
|
|
6783
6911
|
class: "flex items-center qas-nested-fields__actions"
|
|
6784
6912
|
};
|
|
6785
|
-
const _hoisted_7 = { class: "col-auto" };
|
|
6786
6913
|
const _hoisted_8 = { class: "col-auto" };
|
|
6787
|
-
const _hoisted_9 = { class: "col-
|
|
6788
|
-
const _hoisted_10 = { class: "
|
|
6789
|
-
const _hoisted_11 = { class: "
|
|
6790
|
-
const _hoisted_12 = { class: "col
|
|
6791
|
-
const _hoisted_13 = {
|
|
6914
|
+
const _hoisted_9 = { class: "col-auto" };
|
|
6915
|
+
const _hoisted_10 = { class: "col-12" };
|
|
6916
|
+
const _hoisted_11 = { class: "q-mt-md" };
|
|
6917
|
+
const _hoisted_12 = { class: "col" };
|
|
6918
|
+
const _hoisted_13 = { class: "col-auto" };
|
|
6919
|
+
const _hoisted_14 = {
|
|
6792
6920
|
key: 1,
|
|
6793
6921
|
class: "q-mt-lg"
|
|
6794
6922
|
};
|
|
@@ -6811,134 +6939,122 @@
|
|
|
6811
6939
|
}, null, 8 /* PROPS */, ["label"]))
|
|
6812
6940
|
: vue.createCommentVNode("v-if", true)
|
|
6813
6941
|
]),
|
|
6814
|
-
vue.createElementVNode("div",
|
|
6815
|
-
(vue.openBlock(), vue.createBlock(vue.resolveDynamicComponent($options.componentTag), {
|
|
6816
|
-
ref: "inputContent",
|
|
6817
|
-
name: "fade",
|
|
6818
|
-
tag: "div"
|
|
6819
|
-
}, {
|
|
6942
|
+
vue.createElementVNode("div", _hoisted_3$3, [
|
|
6943
|
+
(vue.openBlock(), vue.createBlock(vue.resolveDynamicComponent($options.componentTag), vue.normalizeProps(vue.guardReactiveProps($options.componentProps)), {
|
|
6820
6944
|
default: vue.withCtx(() => [
|
|
6821
6945
|
(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList($data.nested, (row, index) => {
|
|
6822
6946
|
return (vue.openBlock(), vue.createElementBlock("div", {
|
|
6823
6947
|
id: `row-${index}`,
|
|
6824
|
-
key: index
|
|
6948
|
+
key: `row-${index}`,
|
|
6825
6949
|
class: "full-width"
|
|
6826
6950
|
}, [
|
|
6827
|
-
(
|
|
6828
|
-
|
|
6829
|
-
|
|
6830
|
-
|
|
6831
|
-
|
|
6832
|
-
|
|
6833
|
-
|
|
6834
|
-
|
|
6835
|
-
|
|
6951
|
+
(!row[$props.destroyKey])
|
|
6952
|
+
? (vue.openBlock(), vue.createElementBlock("div", {
|
|
6953
|
+
key: index,
|
|
6954
|
+
class: "col-12 q-mt-md"
|
|
6955
|
+
}, [
|
|
6956
|
+
vue.createElementVNode("div", null, [
|
|
6957
|
+
vue.createElementVNode("div", _hoisted_5$2, [
|
|
6958
|
+
(!$props.useSingleLabel)
|
|
6959
|
+
? (vue.openBlock(), vue.createBlock(_component_qas_label, {
|
|
6960
|
+
key: 0,
|
|
6961
|
+
label: $options.setRowLabel(index)
|
|
6962
|
+
}, null, 8 /* PROPS */, ["label"]))
|
|
6963
|
+
: vue.createCommentVNode("v-if", true),
|
|
6964
|
+
(!$props.useInlineActions)
|
|
6965
|
+
? (vue.openBlock(), vue.createElementBlock("div", _hoisted_6, [
|
|
6966
|
+
($props.useDuplicate)
|
|
6967
|
+
? (vue.openBlock(), vue.createBlock(_component_qas_btn, vue.mergeProps({ key: 0 }, $props.btnDuplicateProps, {
|
|
6968
|
+
onClick: $event => ($options.add(row))
|
|
6969
|
+
}), null, 16 /* FULL_PROPS */, ["onClick"]))
|
|
6970
|
+
: vue.createCommentVNode("v-if", true),
|
|
6971
|
+
($options.showDestroyBtn)
|
|
6972
|
+
? (vue.openBlock(), vue.createBlock(_component_qas_btn, vue.mergeProps({ key: 1 }, $props.btnDestroyProps, {
|
|
6973
|
+
onClick: $event => ($options.destroy(index, row))
|
|
6974
|
+
}), null, 16 /* FULL_PROPS */, ["onClick"]))
|
|
6975
|
+
: vue.createCommentVNode("v-if", true)
|
|
6976
|
+
]))
|
|
6977
|
+
: vue.createCommentVNode("v-if", true)
|
|
6978
|
+
]),
|
|
6979
|
+
vue.createElementVNode("div", {
|
|
6980
|
+
ref_for: true,
|
|
6981
|
+
ref: "formGenerator",
|
|
6982
|
+
class: "col-12 justify-between q-col-gutter-x-md row"
|
|
6836
6983
|
}, [
|
|
6837
|
-
vue.
|
|
6838
|
-
|
|
6839
|
-
|
|
6840
|
-
|
|
6841
|
-
|
|
6842
|
-
|
|
6843
|
-
|
|
6844
|
-
|
|
6845
|
-
(
|
|
6846
|
-
|
|
6847
|
-
|
|
6848
|
-
|
|
6849
|
-
|
|
6850
|
-
|
|
6851
|
-
|
|
6852
|
-
|
|
6853
|
-
|
|
6854
|
-
|
|
6855
|
-
|
|
6856
|
-
|
|
6857
|
-
|
|
6858
|
-
|
|
6859
|
-
|
|
6860
|
-
|
|
6861
|
-
|
|
6862
|
-
ref: "formGenerator",
|
|
6863
|
-
class: "col-12 justify-between q-col-gutter-x-md row"
|
|
6864
|
-
}, [
|
|
6865
|
-
vue.renderSlot(_ctx.$slots, "fields", {
|
|
6866
|
-
errors: $options.transformedErrors,
|
|
6867
|
-
fields: $options.children,
|
|
6868
|
-
index: index,
|
|
6869
|
-
updateValue: $options.updateValuesFromInput
|
|
6870
|
-
}, () => [
|
|
6871
|
-
vue.createVNode(_component_qas_form_generator, {
|
|
6872
|
-
modelValue: $data.nested[index],
|
|
6873
|
-
"onUpdate:modelValue": [$event => (($data.nested[index]) = $event), $event => ($options.updateValuesFromInput($event, index))],
|
|
6874
|
-
class: vue.normalizeClass($options.formClasses),
|
|
6875
|
-
columns: $props.formColumns,
|
|
6876
|
-
errors: $options.transformedErrors[index],
|
|
6877
|
-
fields: $options.children,
|
|
6878
|
-
"fields-props": $props.fieldsProps
|
|
6879
|
-
}, vue.createSlots({ _: 2 /* DYNAMIC */ }, [
|
|
6880
|
-
vue.renderList(_ctx.$slots, (slot, key) => {
|
|
6881
|
-
return {
|
|
6882
|
-
name: key,
|
|
6883
|
-
fn: vue.withCtx((scope) => [
|
|
6884
|
-
vue.renderSlot(_ctx.$slots, key, vue.mergeProps(scope, {
|
|
6885
|
-
errors: $options.transformedErrors,
|
|
6886
|
-
index: index
|
|
6887
|
-
}))
|
|
6888
|
-
])
|
|
6889
|
-
}
|
|
6890
|
-
})
|
|
6891
|
-
]), 1032 /* PROPS, DYNAMIC_SLOTS */, ["modelValue", "onUpdate:modelValue", "class", "columns", "errors", "fields", "fields-props"])
|
|
6892
|
-
]),
|
|
6893
|
-
($props.useInlineActions)
|
|
6894
|
-
? (vue.openBlock(), vue.createElementBlock("div", _hoisted_6, [
|
|
6895
|
-
vue.createElementVNode("div", _hoisted_7, [
|
|
6896
|
-
($props.useDuplicate)
|
|
6897
|
-
? (vue.openBlock(), vue.createBlock(_component_qas_btn, {
|
|
6898
|
-
key: 0,
|
|
6899
|
-
color: "primary",
|
|
6900
|
-
flat: "",
|
|
6901
|
-
icon: "o_content_copy",
|
|
6902
|
-
round: "",
|
|
6903
|
-
onClick: $event => ($options.add(row))
|
|
6904
|
-
}, null, 8 /* PROPS */, ["onClick"]))
|
|
6905
|
-
: vue.createCommentVNode("v-if", true)
|
|
6906
|
-
]),
|
|
6907
|
-
vue.createElementVNode("div", _hoisted_8, [
|
|
6908
|
-
($options.showDestroyBtn)
|
|
6909
|
-
? (vue.openBlock(), vue.createBlock(_component_qas_btn, {
|
|
6910
|
-
key: 0,
|
|
6911
|
-
color: "negative",
|
|
6912
|
-
flat: "",
|
|
6913
|
-
icon: "o_cancel",
|
|
6914
|
-
round: "",
|
|
6915
|
-
onClick: $event => ($options.destroy(index, row))
|
|
6916
|
-
}, null, 8 /* PROPS */, ["onClick"]))
|
|
6917
|
-
: vue.createCommentVNode("v-if", true)
|
|
6918
|
-
])
|
|
6919
|
-
]))
|
|
6920
|
-
: vue.createCommentVNode("v-if", true)
|
|
6921
|
-
], 512 /* NEED_PATCH */),
|
|
6922
|
-
vue.createElementVNode("div", _hoisted_9, [
|
|
6923
|
-
vue.renderSlot(_ctx.$slots, "custom-fields", {
|
|
6924
|
-
fields: $options.children,
|
|
6925
|
-
index: index,
|
|
6926
|
-
model: $data.nested[index],
|
|
6927
|
-
updateValue: $options.updateValuesFromInput
|
|
6984
|
+
vue.renderSlot(_ctx.$slots, "fields", {
|
|
6985
|
+
errors: $options.transformedErrors,
|
|
6986
|
+
fields: $options.children,
|
|
6987
|
+
index: index,
|
|
6988
|
+
updateValue: $options.updateValuesFromInput
|
|
6989
|
+
}, () => [
|
|
6990
|
+
vue.createVNode(_component_qas_form_generator, {
|
|
6991
|
+
modelValue: $data.nested[index],
|
|
6992
|
+
"onUpdate:modelValue": [$event => (($data.nested[index]) = $event), $event => ($options.updateValuesFromInput($event, index))],
|
|
6993
|
+
class: vue.normalizeClass($options.formClasses),
|
|
6994
|
+
columns: $props.formColumns,
|
|
6995
|
+
errors: $options.transformedErrors[index],
|
|
6996
|
+
fields: $options.children,
|
|
6997
|
+
"fields-props": $props.fieldsProps
|
|
6998
|
+
}, vue.createSlots({ _: 2 /* DYNAMIC */ }, [
|
|
6999
|
+
vue.renderList(_ctx.$slots, (slot, key) => {
|
|
7000
|
+
return {
|
|
7001
|
+
name: key,
|
|
7002
|
+
fn: vue.withCtx((scope) => [
|
|
7003
|
+
vue.renderSlot(_ctx.$slots, key, vue.mergeProps(scope, {
|
|
7004
|
+
errors: $options.transformedErrors,
|
|
7005
|
+
index: index
|
|
7006
|
+
}))
|
|
7007
|
+
])
|
|
7008
|
+
}
|
|
6928
7009
|
})
|
|
6929
|
-
])
|
|
6930
|
-
])
|
|
6931
|
-
|
|
6932
|
-
|
|
6933
|
-
|
|
6934
|
-
|
|
6935
|
-
|
|
6936
|
-
|
|
7010
|
+
]), 1032 /* PROPS, DYNAMIC_SLOTS */, ["modelValue", "onUpdate:modelValue", "class", "columns", "errors", "fields", "fields-props"])
|
|
7011
|
+
]),
|
|
7012
|
+
($props.useInlineActions)
|
|
7013
|
+
? (vue.openBlock(), vue.createElementBlock("div", _hoisted_7, [
|
|
7014
|
+
vue.createElementVNode("div", _hoisted_8, [
|
|
7015
|
+
($props.useDuplicate)
|
|
7016
|
+
? (vue.openBlock(), vue.createBlock(_component_qas_btn, {
|
|
7017
|
+
key: 0,
|
|
7018
|
+
color: "primary",
|
|
7019
|
+
flat: "",
|
|
7020
|
+
icon: "o_content_copy",
|
|
7021
|
+
round: "",
|
|
7022
|
+
onClick: $event => ($options.add(row))
|
|
7023
|
+
}, null, 8 /* PROPS */, ["onClick"]))
|
|
7024
|
+
: vue.createCommentVNode("v-if", true)
|
|
7025
|
+
]),
|
|
7026
|
+
vue.createElementVNode("div", _hoisted_9, [
|
|
7027
|
+
($options.showDestroyBtn)
|
|
7028
|
+
? (vue.openBlock(), vue.createBlock(_component_qas_btn, {
|
|
7029
|
+
key: 0,
|
|
7030
|
+
color: "negative",
|
|
7031
|
+
flat: "",
|
|
7032
|
+
icon: "o_cancel",
|
|
7033
|
+
round: "",
|
|
7034
|
+
onClick: $event => ($options.destroy(index, row))
|
|
7035
|
+
}, null, 8 /* PROPS */, ["onClick"]))
|
|
7036
|
+
: vue.createCommentVNode("v-if", true)
|
|
7037
|
+
])
|
|
7038
|
+
]))
|
|
7039
|
+
: vue.createCommentVNode("v-if", true)
|
|
7040
|
+
], 512 /* NEED_PATCH */),
|
|
7041
|
+
vue.createElementVNode("div", _hoisted_10, [
|
|
7042
|
+
vue.renderSlot(_ctx.$slots, "custom-fields", {
|
|
7043
|
+
fields: $options.children,
|
|
7044
|
+
index: index,
|
|
7045
|
+
model: $data.nested[index],
|
|
7046
|
+
updateValue: $options.updateValuesFromInput
|
|
7047
|
+
})
|
|
7048
|
+
])
|
|
7049
|
+
])
|
|
7050
|
+
]))
|
|
7051
|
+
: vue.createCommentVNode("v-if", true)
|
|
7052
|
+
], 8 /* PROPS */, _hoisted_4$3))
|
|
6937
7053
|
}), 128 /* KEYED_FRAGMENT */))
|
|
6938
7054
|
]),
|
|
6939
7055
|
_: 3 /* FORWARDED */
|
|
6940
|
-
},
|
|
6941
|
-
vue.createElementVNode("div",
|
|
7056
|
+
}, 16 /* FULL_PROPS */)),
|
|
7057
|
+
vue.createElementVNode("div", _hoisted_11, [
|
|
6942
7058
|
vue.renderSlot(_ctx.$slots, "add-input", { add: $options.add }, () => [
|
|
6943
7059
|
($props.useInlineActions)
|
|
6944
7060
|
? (vue.openBlock(), vue.createElementBlock("div", {
|
|
@@ -6946,7 +7062,7 @@
|
|
|
6946
7062
|
class: "cursor-pointer items-center q-col-gutter-x-md q-mt-md row",
|
|
6947
7063
|
onClick: _cache[1] || (_cache[1] = $event => ($options.add()))
|
|
6948
7064
|
}, [
|
|
6949
|
-
vue.createElementVNode("div",
|
|
7065
|
+
vue.createElementVNode("div", _hoisted_12, [
|
|
6950
7066
|
vue.createVNode(_component_qas_input, {
|
|
6951
7067
|
class: "disabled no-pointer-events",
|
|
6952
7068
|
"hide-bottom-space": "",
|
|
@@ -6955,7 +7071,7 @@
|
|
|
6955
7071
|
onFocus: _cache[0] || (_cache[0] = $event => ($options.add()))
|
|
6956
7072
|
}, null, 8 /* PROPS */, ["label"])
|
|
6957
7073
|
]),
|
|
6958
|
-
vue.createElementVNode("div",
|
|
7074
|
+
vue.createElementVNode("div", _hoisted_13, [
|
|
6959
7075
|
vue.createVNode(_component_qas_btn, {
|
|
6960
7076
|
color: "green",
|
|
6961
7077
|
flat: "",
|
|
@@ -6964,9 +7080,9 @@
|
|
|
6964
7080
|
})
|
|
6965
7081
|
])
|
|
6966
7082
|
]))
|
|
6967
|
-
: (vue.openBlock(), vue.createElementBlock("div",
|
|
7083
|
+
: (vue.openBlock(), vue.createElementBlock("div", _hoisted_14, [
|
|
6968
7084
|
vue.createVNode(_component_qas_btn, {
|
|
6969
|
-
class: "full-width q-py-
|
|
7085
|
+
class: "full-width q-py-md",
|
|
6970
7086
|
icon: "o_add",
|
|
6971
7087
|
outline: "",
|
|
6972
7088
|
onClick: _cache[2] || (_cache[2] = $event => ($options.add()))
|
|
@@ -6979,13 +7095,15 @@
|
|
|
6979
7095
|
]))
|
|
6980
7096
|
])
|
|
6981
7097
|
])
|
|
6982
|
-
])
|
|
7098
|
+
], 512 /* NEED_PATCH */)
|
|
6983
7099
|
], 8 /* PROPS */, _hoisted_1$8))
|
|
6984
7100
|
}
|
|
6985
7101
|
|
|
6986
7102
|
script$c.render = render$c;
|
|
6987
7103
|
script$c.__file = "src/components/nested-fields/QasNestedFields.vue";
|
|
6988
7104
|
|
|
7105
|
+
const { hasPreviousRoute, history: history$1, getPreviousRoute } = useHistory();
|
|
7106
|
+
|
|
6989
7107
|
var script$b = {
|
|
6990
7108
|
name: 'QasPageHeader',
|
|
6991
7109
|
|
|
@@ -7013,7 +7131,7 @@
|
|
|
7013
7131
|
|
|
7014
7132
|
computed: {
|
|
7015
7133
|
hasPreviousRoute () {
|
|
7016
|
-
return
|
|
7134
|
+
return hasPreviousRoute.value
|
|
7017
7135
|
},
|
|
7018
7136
|
|
|
7019
7137
|
transformedBreadcrumbs () {
|
|
@@ -7130,8 +7248,6 @@
|
|
|
7130
7248
|
QasGridGenerator: script$i
|
|
7131
7249
|
},
|
|
7132
7250
|
|
|
7133
|
-
mixins: [screenMixin],
|
|
7134
|
-
|
|
7135
7251
|
props: {
|
|
7136
7252
|
columns: {
|
|
7137
7253
|
type: Object,
|
|
@@ -7172,7 +7288,7 @@
|
|
|
7172
7288
|
|
|
7173
7289
|
computed: {
|
|
7174
7290
|
directionClasses () {
|
|
7175
|
-
return this.
|
|
7291
|
+
return this.$qas.screen.untilMedium ? 'col' : 'row items-center'
|
|
7176
7292
|
},
|
|
7177
7293
|
|
|
7178
7294
|
userAvatarImage () {
|
|
@@ -7180,7 +7296,7 @@
|
|
|
7180
7296
|
},
|
|
7181
7297
|
|
|
7182
7298
|
avatarSize () {
|
|
7183
|
-
return this.
|
|
7299
|
+
return this.$qas.screen.isSmall ? '145px' : '188px'
|
|
7184
7300
|
}
|
|
7185
7301
|
},
|
|
7186
7302
|
|
|
@@ -7448,6 +7564,7 @@
|
|
|
7448
7564
|
this.fuse = new Fuse__default["default"](value, this.defaultFuseOptions);
|
|
7449
7565
|
|
|
7450
7566
|
this.setResults(this.search);
|
|
7567
|
+
this.updateResultsModel(value);
|
|
7451
7568
|
},
|
|
7452
7569
|
|
|
7453
7570
|
deep: true
|
|
@@ -7464,7 +7581,7 @@
|
|
|
7464
7581
|
|
|
7465
7582
|
searchResults: {
|
|
7466
7583
|
handler (value) {
|
|
7467
|
-
this
|
|
7584
|
+
this.updateResultsModel(value);
|
|
7468
7585
|
},
|
|
7469
7586
|
immediate: true
|
|
7470
7587
|
}
|
|
@@ -7481,6 +7598,10 @@
|
|
|
7481
7598
|
this.searchResults = value
|
|
7482
7599
|
? this.fuse.search(value)
|
|
7483
7600
|
: this.list;
|
|
7601
|
+
},
|
|
7602
|
+
|
|
7603
|
+
updateResultsModel (value) {
|
|
7604
|
+
this.$emit('update:results', value.map(result => result.item || result));
|
|
7484
7605
|
}
|
|
7485
7606
|
}
|
|
7486
7607
|
};
|
|
@@ -7756,8 +7877,6 @@
|
|
|
7756
7877
|
QasSearchBox: script$8
|
|
7757
7878
|
},
|
|
7758
7879
|
|
|
7759
|
-
mixins: [screenMixin],
|
|
7760
|
-
|
|
7761
7880
|
props: {
|
|
7762
7881
|
deleteOnly: {
|
|
7763
7882
|
type: Boolean
|
|
@@ -7838,15 +7957,17 @@
|
|
|
7838
7957
|
immediate: true
|
|
7839
7958
|
},
|
|
7840
7959
|
|
|
7841
|
-
modelValue
|
|
7842
|
-
|
|
7960
|
+
modelValue: {
|
|
7961
|
+
handler (value) {
|
|
7962
|
+
this.values = [...value];
|
|
7963
|
+
},
|
|
7964
|
+
|
|
7965
|
+
immediate: true
|
|
7843
7966
|
}
|
|
7844
7967
|
},
|
|
7845
7968
|
|
|
7846
7969
|
created () {
|
|
7847
|
-
this.
|
|
7848
|
-
|
|
7849
|
-
this.handleOptions();
|
|
7970
|
+
this.handleList();
|
|
7850
7971
|
},
|
|
7851
7972
|
|
|
7852
7973
|
methods: {
|
|
@@ -7861,9 +7982,9 @@
|
|
|
7861
7982
|
const isSelected = this.values.includes(value);
|
|
7862
7983
|
|
|
7863
7984
|
return {
|
|
7864
|
-
dense: this.
|
|
7985
|
+
dense: this.$qas.screen.isSmall,
|
|
7865
7986
|
hideLabelOnSmallScreen: true,
|
|
7866
|
-
icon: !this.
|
|
7987
|
+
icon: !this.$qas.screen.isSmall ? undefined : isSelected ? 'o_close' : 'o_add',
|
|
7867
7988
|
label: isSelected ? 'Remover' : 'Adicionar',
|
|
7868
7989
|
outline: isSelected,
|
|
7869
7990
|
size: 'sm'
|
|
@@ -7874,7 +7995,7 @@
|
|
|
7874
7995
|
return this.values.includes(item.value) ? this.remove(item) : this.add(item)
|
|
7875
7996
|
},
|
|
7876
7997
|
|
|
7877
|
-
|
|
7998
|
+
handleList () {
|
|
7878
7999
|
if (this.modelValue.length) {
|
|
7879
8000
|
return this.sortList()
|
|
7880
8001
|
}
|
|
@@ -7905,8 +8026,8 @@
|
|
|
7905
8026
|
|
|
7906
8027
|
sortList () {
|
|
7907
8028
|
this.sortedList = this.deleteOnly
|
|
7908
|
-
? this.list.filter(
|
|
7909
|
-
: lodashEs.sortBy(this.list,
|
|
8029
|
+
? this.list.filter(item => this.modelValue.includes(item.value))
|
|
8030
|
+
: lodashEs.sortBy(this.list, item => !this.modelValue.includes(item.value));
|
|
7910
8031
|
},
|
|
7911
8032
|
|
|
7912
8033
|
updateModel (model) {
|
|
@@ -8264,8 +8385,6 @@
|
|
|
8264
8385
|
var script$3 = {
|
|
8265
8386
|
name: 'QasTableGenerator',
|
|
8266
8387
|
|
|
8267
|
-
mixins: [screenMixin],
|
|
8268
|
-
|
|
8269
8388
|
props: {
|
|
8270
8389
|
columns: {
|
|
8271
8390
|
default: () => [],
|
|
@@ -8392,7 +8511,7 @@
|
|
|
8392
8511
|
},
|
|
8393
8512
|
|
|
8394
8513
|
tableClass () {
|
|
8395
|
-
return this.
|
|
8514
|
+
return this.$qas.screen.isSmall && 'qas-table-generator--mobile'
|
|
8396
8515
|
},
|
|
8397
8516
|
|
|
8398
8517
|
hasScrollOnGrab () {
|
|
@@ -8433,8 +8552,8 @@
|
|
|
8433
8552
|
},
|
|
8434
8553
|
|
|
8435
8554
|
getFullTableWidth () {
|
|
8436
|
-
const
|
|
8437
|
-
return
|
|
8555
|
+
const tableElement = this.getTableElement();
|
|
8556
|
+
return tableElement?.getBoundingClientRect?.()?.width
|
|
8438
8557
|
},
|
|
8439
8558
|
|
|
8440
8559
|
getContainerTableWidth () {
|
|
@@ -8633,8 +8752,6 @@
|
|
|
8633
8752
|
QasDialog: script$x
|
|
8634
8753
|
},
|
|
8635
8754
|
|
|
8636
|
-
mixins: [screenMixin],
|
|
8637
|
-
|
|
8638
8755
|
props: {
|
|
8639
8756
|
dialogProps: {
|
|
8640
8757
|
type: Object,
|
|
@@ -8674,7 +8791,7 @@
|
|
|
8674
8791
|
|
|
8675
8792
|
computed: {
|
|
8676
8793
|
truncateTextClass () {
|
|
8677
|
-
return (this.isTruncated || this.
|
|
8794
|
+
return (this.isTruncated || this.$qas.screen.isSmall) && 'ellipsis q-pr-sm'
|
|
8678
8795
|
},
|
|
8679
8796
|
|
|
8680
8797
|
isTruncated () {
|
|
@@ -8776,8 +8893,6 @@
|
|
|
8776
8893
|
QasSearchBox: script$8
|
|
8777
8894
|
},
|
|
8778
8895
|
|
|
8779
|
-
mixins: [screenMixin],
|
|
8780
|
-
|
|
8781
8896
|
props: {
|
|
8782
8897
|
emitValue: {
|
|
8783
8898
|
type: Boolean
|
|
@@ -8827,21 +8942,23 @@
|
|
|
8827
8942
|
firstQueue: [],
|
|
8828
8943
|
optionsList: [],
|
|
8829
8944
|
secondQueue: [],
|
|
8830
|
-
selectedList: []
|
|
8945
|
+
selectedList: [],
|
|
8946
|
+
firstResults: [],
|
|
8947
|
+
secondResults: []
|
|
8831
8948
|
}
|
|
8832
8949
|
},
|
|
8833
8950
|
|
|
8834
8951
|
computed: {
|
|
8835
8952
|
actionsClass () {
|
|
8836
|
-
return !this.
|
|
8953
|
+
return !this.$qas.screen.isSmall && 'column'
|
|
8837
8954
|
},
|
|
8838
8955
|
|
|
8839
8956
|
gutterClass () {
|
|
8840
|
-
return `q-col-gutter-${this.
|
|
8957
|
+
return `q-col-gutter-${this.$qas.screen.untilLarge ? 'md' : 'xl'}`
|
|
8841
8958
|
},
|
|
8842
8959
|
|
|
8843
8960
|
iconClass () {
|
|
8844
|
-
return !this.
|
|
8961
|
+
return !this.$qas.screen.isSmall && 'qas-transfer__icon'
|
|
8845
8962
|
},
|
|
8846
8963
|
|
|
8847
8964
|
searchBoxProps () {
|
|
@@ -8965,13 +9082,15 @@
|
|
|
8965
9082
|
quantity: $data.optionsList.length
|
|
8966
9083
|
}, null, 8 /* PROPS */, ["label", "quantity"]),
|
|
8967
9084
|
vue.createVNode(_component_qas_search_box, vue.mergeProps({
|
|
8968
|
-
|
|
8969
|
-
|
|
9085
|
+
results: $data.firstResults,
|
|
9086
|
+
"onUpdate:results": _cache[0] || (_cache[0] = $event => (($data.firstResults) = $event)),
|
|
9087
|
+
list: $data.optionsList,
|
|
9088
|
+
outlined: ""
|
|
8970
9089
|
}, $options.searchBoxProps), {
|
|
8971
|
-
default: vue.withCtx((
|
|
9090
|
+
default: vue.withCtx(() => [
|
|
8972
9091
|
vue.createVNode(_component_q_list, { separator: "" }, {
|
|
8973
9092
|
default: vue.withCtx(() => [
|
|
8974
|
-
(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(
|
|
9093
|
+
(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList($data.firstResults, (item, index) => {
|
|
8975
9094
|
return (vue.openBlock(), vue.createBlock(_component_q_item, {
|
|
8976
9095
|
key: index,
|
|
8977
9096
|
class: vue.normalizeClass($options.getItemClass(item, true)),
|
|
@@ -8992,11 +9111,11 @@
|
|
|
8992
9111
|
}, 1032 /* PROPS, DYNAMIC_SLOTS */, ["class", "onClick"]))
|
|
8993
9112
|
}), 128 /* KEYED_FRAGMENT */))
|
|
8994
9113
|
]),
|
|
8995
|
-
_:
|
|
8996
|
-
}
|
|
9114
|
+
_: 3 /* FORWARDED */
|
|
9115
|
+
})
|
|
8997
9116
|
]),
|
|
8998
9117
|
_: 3 /* FORWARDED */
|
|
8999
|
-
}, 16 /* FULL_PROPS */, ["list"])
|
|
9118
|
+
}, 16 /* FULL_PROPS */, ["results", "list"])
|
|
9000
9119
|
]),
|
|
9001
9120
|
vue.createElementVNode("div", {
|
|
9002
9121
|
class: vue.normalizeClass(["col-12 col-sm-auto items-center justify-center q-col-gutter-md row", $options.actionsClass])
|
|
@@ -9009,7 +9128,7 @@
|
|
|
9009
9128
|
flat: "",
|
|
9010
9129
|
icon: "o_arrow_circle_down",
|
|
9011
9130
|
rounded: "",
|
|
9012
|
-
onClick: _cache[
|
|
9131
|
+
onClick: _cache[1] || (_cache[1] = $event => ($options.setSelectedFromClick(true)))
|
|
9013
9132
|
}, null, 8 /* PROPS */, ["class", "disabled"]),
|
|
9014
9133
|
vue.createVNode(_component_q_tooltip, {
|
|
9015
9134
|
anchor: "top middle",
|
|
@@ -9030,7 +9149,7 @@
|
|
|
9030
9149
|
flat: "",
|
|
9031
9150
|
icon: "o_arrow_circle_up",
|
|
9032
9151
|
rounded: "",
|
|
9033
|
-
onClick: _cache[
|
|
9152
|
+
onClick: _cache[2] || (_cache[2] = $event => ($options.setSelectedFromClick()))
|
|
9034
9153
|
}, null, 8 /* PROPS */, ["class", "disabled"]),
|
|
9035
9154
|
vue.createVNode(_component_q_tooltip, {
|
|
9036
9155
|
anchor: "bottom middle",
|
|
@@ -9049,16 +9168,19 @@
|
|
|
9049
9168
|
label: "Selecionadas",
|
|
9050
9169
|
quantity: $data.selectedList.length
|
|
9051
9170
|
}, null, 8 /* PROPS */, ["quantity"]),
|
|
9052
|
-
vue.createVNode(_component_qas_search_box, vue.mergeProps(
|
|
9171
|
+
vue.createVNode(_component_qas_search_box, vue.mergeProps({
|
|
9172
|
+
results: $data.secondResults,
|
|
9173
|
+
"onUpdate:results": _cache[3] || (_cache[3] = $event => (($data.secondResults) = $event))
|
|
9174
|
+
}, $options.searchBoxProps, {
|
|
9053
9175
|
"empty-list-height": "300px",
|
|
9054
|
-
"form-mode": "",
|
|
9055
9176
|
label: "Selecionadas",
|
|
9056
|
-
list: $data.selectedList
|
|
9177
|
+
list: $data.selectedList,
|
|
9178
|
+
outlined: ""
|
|
9057
9179
|
}), {
|
|
9058
|
-
default: vue.withCtx((
|
|
9180
|
+
default: vue.withCtx(() => [
|
|
9059
9181
|
vue.createVNode(_component_q_list, { separator: "" }, {
|
|
9060
9182
|
default: vue.withCtx(() => [
|
|
9061
|
-
(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(
|
|
9183
|
+
(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList($data.secondResults, (item, index) => {
|
|
9062
9184
|
return (vue.openBlock(), vue.createBlock(_component_q_item, {
|
|
9063
9185
|
key: index,
|
|
9064
9186
|
class: vue.normalizeClass($options.getItemClass(item)),
|
|
@@ -9079,11 +9201,11 @@
|
|
|
9079
9201
|
}, 1032 /* PROPS, DYNAMIC_SLOTS */, ["class", "onClick"]))
|
|
9080
9202
|
}), 128 /* KEYED_FRAGMENT */))
|
|
9081
9203
|
]),
|
|
9082
|
-
_:
|
|
9083
|
-
}
|
|
9204
|
+
_: 3 /* FORWARDED */
|
|
9205
|
+
})
|
|
9084
9206
|
]),
|
|
9085
9207
|
_: 3 /* FORWARDED */
|
|
9086
|
-
}, 16 /* FULL_PROPS */, ["list"])
|
|
9208
|
+
}, 16 /* FULL_PROPS */, ["results", "list"])
|
|
9087
9209
|
])
|
|
9088
9210
|
], 2 /* CLASS */))
|
|
9089
9211
|
}
|
|
@@ -9093,7 +9215,7 @@
|
|
|
9093
9215
|
|
|
9094
9216
|
var name = "@bildvitta/quasar-ui-asteroid";
|
|
9095
9217
|
var description = "Asteroid";
|
|
9096
|
-
var version$1 = "3.0.0-
|
|
9218
|
+
var version$1 = "3.0.0-beta.3";
|
|
9097
9219
|
var author = "Bild & Vitta <systemteam@bild.com.br>";
|
|
9098
9220
|
var license = "MIT";
|
|
9099
9221
|
var main = "dist/asteroid.cjs.min.js";
|
|
@@ -9174,6 +9296,20 @@
|
|
|
9174
9296
|
vetur: vetur
|
|
9175
9297
|
};
|
|
9176
9298
|
|
|
9299
|
+
var Test = {
|
|
9300
|
+
name: 'test',
|
|
9301
|
+
|
|
9302
|
+
bind (element, { arg: argument, value }) {
|
|
9303
|
+
if (element && argument) {
|
|
9304
|
+
element.dataset.test = argument;
|
|
9305
|
+
}
|
|
9306
|
+
|
|
9307
|
+
if (element && value) {
|
|
9308
|
+
element.dataset.testKey = value;
|
|
9309
|
+
}
|
|
9310
|
+
}
|
|
9311
|
+
};
|
|
9312
|
+
|
|
9177
9313
|
const version = packageInfo.version;
|
|
9178
9314
|
|
|
9179
9315
|
function install (app) {
|
|
@@ -9235,8 +9371,11 @@
|
|
|
9235
9371
|
app.config.globalProperties.$qas = {
|
|
9236
9372
|
dialog: Dialog,
|
|
9237
9373
|
error: NotifyError,
|
|
9238
|
-
success: NotifySuccess
|
|
9374
|
+
success: NotifySuccess,
|
|
9375
|
+
screen: Screen()
|
|
9239
9376
|
};
|
|
9377
|
+
|
|
9378
|
+
app.directive(Test.name, Test);
|
|
9240
9379
|
}
|
|
9241
9380
|
|
|
9242
9381
|
var VuePlugin = /*#__PURE__*/Object.freeze({
|
|
@@ -9293,6 +9432,7 @@
|
|
|
9293
9432
|
Dialog: Dialog,
|
|
9294
9433
|
NotifyError: NotifyError,
|
|
9295
9434
|
NotifySuccess: NotifySuccess,
|
|
9435
|
+
Screen: Screen,
|
|
9296
9436
|
install: install
|
|
9297
9437
|
});
|
|
9298
9438
|
|