@tagplus/components 2.0.13 → 2.0.15
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/tp.common.js +1 -1
- package/dist/tp.common.js.map +1 -1
- package/dist/tp.css +2 -2
- package/dist/tp.umd.js +1 -1
- package/dist/tp.umd.js.map +1 -1
- package/dist/tp.umd.min.js +1 -1
- package/dist/tp.umd.min.js.map +1 -1
- package/package.json +1 -1
- package/src/components/Autosuggest/Autosuggest.vue +2 -2
- package/src/components/Multisuggest/Multisuggest.vue +3 -4
package/package.json
CHANGED
|
@@ -304,7 +304,7 @@ export default {
|
|
|
304
304
|
newVal = this.value
|
|
305
305
|
} else if (this.value && typeof this.value === 'object') {
|
|
306
306
|
if (!Object.keys(newVal).length) { return {} }
|
|
307
|
-
if (!this.value[this.valueKey]) {
|
|
307
|
+
if (!this.value[this.valueKey] && this.value[this.valueKey] !== '') {
|
|
308
308
|
if (process.env.DEBUG === 'true') {
|
|
309
309
|
console.error(
|
|
310
310
|
`Autosuggest '${this.$options.name}' option doesn't have a valueKey '${this.valueKey}' key`
|
|
@@ -491,7 +491,7 @@ export default {
|
|
|
491
491
|
} else if (val && typeof val === 'object') {
|
|
492
492
|
if (!Object.keys(val).length) { return {} }
|
|
493
493
|
// Se val for Object converte para outro tipo
|
|
494
|
-
if (!this.value[this.valueKey]) {
|
|
494
|
+
if (!this.value[this.valueKey] && this.value[this.valueKey] !== '') {
|
|
495
495
|
console.error(
|
|
496
496
|
`Autosuggest '${this.$options.name}' option doesn't have a valueKey '${this.valueKey}' key`
|
|
497
497
|
)
|
|
@@ -365,7 +365,7 @@ export default {
|
|
|
365
365
|
newVal = ''
|
|
366
366
|
} else if (Array.isArray(this.value)) {
|
|
367
367
|
this.value.forEach((item) => {
|
|
368
|
-
if (!item[this.valueKey]) {
|
|
368
|
+
if (!item[this.valueKey] && item[this.valueKey] !== '') {
|
|
369
369
|
if (process.env.DEBUG === 'true') {
|
|
370
370
|
console.error(`Multisuggest '${this.$options.name}' option doesn't have a valueKey '${this.valueKey}' key`)
|
|
371
371
|
}
|
|
@@ -556,15 +556,14 @@ export default {
|
|
|
556
556
|
getOption (val) {
|
|
557
557
|
let value = ''
|
|
558
558
|
let initialLabel = false
|
|
559
|
-
|
|
560
559
|
if (typeof this.value === 'boolean') {
|
|
561
560
|
value = ''
|
|
562
|
-
} else if (Array.isArray(
|
|
561
|
+
} else if (Array.isArray(this.value)) {
|
|
563
562
|
value = val
|
|
564
563
|
} else if (val && typeof val === 'object') {
|
|
565
564
|
if (!Object.keys(val).length) { return {} }
|
|
566
565
|
// Se val for Object converte para outro tipo
|
|
567
|
-
if (!
|
|
566
|
+
if (!this.value[this.valueKey] && this.value[this.valueKey] !== '') {
|
|
568
567
|
console.error(`Multisuggest '${this.$options.name}' option doesn't have a valueKey '${this.valueKey}' key`)
|
|
569
568
|
} else {
|
|
570
569
|
// Se mandou a label no objeto value
|