fix issue with SMTP vars mutation
This commit is contained in:
parent
0ccf912a39
commit
2482de80a9
1 changed files with 2 additions and 1 deletions
|
@ -52,6 +52,7 @@ export default {
|
||||||
async testSMTP () {
|
async testSMTP () {
|
||||||
this.loading = true
|
this.loading = true
|
||||||
try {
|
try {
|
||||||
|
this.setSetting({ key: 'smtp', value: this.smtp })
|
||||||
await this.$axios.$post('/settings/smtp', { smtp: this.smtp })
|
await this.$axios.$post('/settings/smtp', { smtp: this.smtp })
|
||||||
this.$root.$message(this.$t('admin.smtp_test_success', { admin_email: this.admin_email }), { color: 'success' })
|
this.$root.$message(this.$t('admin.smtp_test_success', { admin_email: this.admin_email }), { color: 'success' })
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
|
@ -66,8 +67,8 @@ export default {
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
done () {
|
done () {
|
||||||
|
this.setSetting({ key: 'smtp', value: JSON.parse(JSON.stringify(this.smtp)) })
|
||||||
this.$emit('close')
|
this.$emit('close')
|
||||||
this.setSetting({ key: 'smtp', value: this.smtp })
|
|
||||||
},
|
},
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue