Fix theme upload loading bug

pull/3445/head
johnniang 2019-06-12 01:03:19 +08:00
parent d188ecc136
commit d10a9977fd
1 changed files with 10 additions and 6 deletions

View File

@ -456,12 +456,16 @@ export default {
}, },
handleFetching() { handleFetching() {
this.fetchButtonLoading = true this.fetchButtonLoading = true
themeApi.fetching(this.fetchingUrl).then(response => { themeApi
this.$message.success('拉取成功!') .fetching(this.fetchingUrl)
this.uploadVisible = false .then(response => {
this.fetchButtonLoading = false this.$message.success('拉取成功!')
this.loadThemes() this.uploadVisible = false
}) this.loadThemes()
})
.finally(() => {
this.fetchButtonLoading = false
})
}, },
handleReload() { handleReload() {
themeApi.reload().then(response => { themeApi.reload().then(response => {