BUG 25531
This commit is contained in:
@@ -121,11 +121,9 @@ export default {
|
|||||||
uni.showLoading({title: '上传中'})
|
uni.showLoading({title: '上传中'})
|
||||||
let formData = new FormData()
|
let formData = new FormData()
|
||||||
formData.append('file', img)
|
formData.append('file', img)
|
||||||
this.$http
|
this.$http.post(this.action, formData, {
|
||||||
.post(this.action, formData, {
|
|
||||||
params: {type: this.type},
|
params: {type: this.type},
|
||||||
})
|
}).then((res) => {
|
||||||
.then((res) => {
|
|
||||||
uni.hideLoading()
|
uni.hideLoading()
|
||||||
if (res?.data) {
|
if (res?.data) {
|
||||||
this.$emit('data', res.data)
|
this.$emit('data', res.data)
|
||||||
@@ -144,8 +142,10 @@ export default {
|
|||||||
} else {
|
} else {
|
||||||
this.$u.toast(res.msg)
|
this.$u.toast(res.msg)
|
||||||
}
|
}
|
||||||
|
}).catch(err => {
|
||||||
|
this.$u.toast(err)
|
||||||
|
uni.hideLoading()
|
||||||
})
|
})
|
||||||
.catch(() => uni.hideLoading())
|
|
||||||
},
|
},
|
||||||
handleReUpload(i) {
|
handleReUpload(i) {
|
||||||
this.upload(() => this.remove(i))
|
this.upload(() => this.remove(i))
|
||||||
|
|||||||
Reference in New Issue
Block a user