fix reset values on deleting me fields

pull/150/merge^2
iozeey 2 years ago
parent f6e86093e7
commit cf628a8ea5

@ -590,27 +590,36 @@ export default {
this.save() this.save()
}, },
removeField () { removeField () {
const templateValue = this.template.values[this.field.uuid]
switch (this.field.type) { switch (this.field.type) {
case 'my_signature': case 'my_signature':
this.showMySignature = false if (this.myLocalSignatureValue === templateValue) {
this.myLocalSignatureValue = '' this.showMySignature = false
this.myLocalSignatureValue = ''
}
console.log('switch signature portion') console.log('switch signature portion')
break break
case 'my_initials': case 'my_initials':
this.showMyInitials = false if (this.myLocalInitialsValue === templateValue) {
this.myLocalInitialsValue = '' this.showMyInitials = false
this.myLocalInitialsValue = ''
}
console.log('switch initials portion') console.log('switch initials portion')
break break
case 'my_date': case 'my_date':
this.showMyDate = false if (this.myLocalDateValue === templateValue) {
this.myLocalDateValue = '' this.showMyDate = false
this.myLocalDateValue = ''
}
console.log('switch my_date portion') console.log('switch my_date portion')
break break
case 'my_text': case 'my_text':
this.myLocalText = '' if (this.myLocalText === templateValue) {
this.myLocalText = ''
}
break break
default: default:
console.log('switch default portion') console.log('switch default portion')

Loading…
Cancel
Save