mirror of https://github.com/halo-dev/halo
Load user when option updating
parent
0922f72fee
commit
afde5dc9f8
|
@ -571,6 +571,7 @@ import AttachmentSelectDrawer from '../attachment/components/AttachmentSelectDra
|
||||||
import optionApi from '@/api/option'
|
import optionApi from '@/api/option'
|
||||||
import mailApi from '@/api/mail'
|
import mailApi from '@/api/mail'
|
||||||
import attachmentApi from '@/api/attachment'
|
import attachmentApi from '@/api/attachment'
|
||||||
|
import { mapActions } from 'vuex'
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
components: {
|
components: {
|
||||||
|
@ -598,6 +599,7 @@ export default {
|
||||||
this.loadOptions()
|
this.loadOptions()
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
...mapActions(['loadUser']),
|
||||||
loadOptions() {
|
loadOptions() {
|
||||||
optionApi.listAll().then(response => {
|
optionApi.listAll().then(response => {
|
||||||
this.options = response.data.data
|
this.options = response.data.data
|
||||||
|
@ -607,11 +609,12 @@ export default {
|
||||||
handleSaveOptions() {
|
handleSaveOptions() {
|
||||||
optionApi.save(this.options).then(response => {
|
optionApi.save(this.options).then(response => {
|
||||||
this.loadOptions()
|
this.loadOptions()
|
||||||
|
this.loadUser()
|
||||||
this.$message.success('保存成功!')
|
this.$message.success('保存成功!')
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
handleAttachChange(e) {
|
handleAttachChange(e) {
|
||||||
switch (e.toUppper()) {
|
switch (e) {
|
||||||
case 'LOCAL':
|
case 'LOCAL':
|
||||||
case 'SMMS':
|
case 'SMMS':
|
||||||
this.upyunFormHidden = false
|
this.upyunFormHidden = false
|
||||||
|
|
Loading…
Reference in New Issue