1
0
mirror of synced 2024-11-25 23:06:02 +03:00

Fixes bug with v-if formulate-elements that had initial values

This commit is contained in:
Justin Schroeder 2018-02-28 11:47:34 -05:00
parent 8581a40662
commit d7bc86b077
2 changed files with 3 additions and 2 deletions

2
dist/index.js vendored

File diff suppressed because one or more lines are too long

View File

@ -104,7 +104,8 @@ export default {
},
hydrate (values) {
for (let field of this.fields) {
if (field.type !== 'submit') {
console.log(`${field.name}: ${typeof this.values[field]}`)
if (field.type !== 'submit' && typeof this.values[field.name] === 'undefined') {
this.$store.commit(`${this.m}setFieldValue`, {
field: field.name,
value: values[field.name],