Encode attachment url.

pull/35/head
ruibaby 2019-07-16 21:43:20 +08:00
parent 99973c0ef2
commit a8434eb04b
6 changed files with 9 additions and 9 deletions

View File

@ -341,7 +341,7 @@ export default {
})
},
handleSelectPostThumb(data) {
this.postToStage.thumbnail = data.path
this.postToStage.thumbnail = encodeURI(data.path)
this.thumDrawerVisible = false
},
autoSaveTimer() {
@ -359,7 +359,7 @@ export default {
if (responseObject.status === 200) {
var MavonEditor = this.$refs.md
MavonEditor.$img2Url(pos, responseObject.data.path)
MavonEditor.$img2Url(pos, encodeURI(responseObject.data.path))
this.$message.success('图片上传成功')
} else {
this.$message.error('图片上传失败:' + responseObject.message)

View File

@ -620,7 +620,7 @@ export default {
})
},
handleSelectPostThumb(data) {
this.selectedPost.thumbnail = data.path
this.selectedPost.thumbnail = encodeURI(data.path)
this.thumDrawerVisible = false
},
handlerRemoveThumb() {

View File

@ -250,7 +250,7 @@ export default {
}
},
handleSelectSheetThumb(data) {
this.sheetToStage.thumbnail = data.path
this.sheetToStage.thumbnail = encodeURI(data.path)
this.thumDrawerVisible = false
},
autoSaveTimer() {
@ -268,7 +268,7 @@ export default {
if (responseObject.status === 200) {
var MavonEditor = this.$refs.md
MavonEditor.$img2Url(pos, responseObject.data.path)
MavonEditor.$img2Url(pos, encodeURI(responseObject.data.path))
this.$message.success('图片上传成功')
} else {
this.$message.error('图片上传失败:' + responseObject.message)

View File

@ -364,7 +364,7 @@ export default {
this.thumDrawerVisible = true
},
selectPhotoThumb(data) {
this.photo.url = data.path
this.photo.url = encodeURI(data.path)
this.thumDrawerVisible = false
},
resetParam() {

View File

@ -649,7 +649,7 @@ export default {
}
},
handleSelectLogo(data) {
this.options.blog_logo = data.path
this.options.blog_logo = encodeURI(data.path)
this.logoDrawerVisible = false
},
handleTestMailClick() {
@ -658,7 +658,7 @@ export default {
})
},
handleSelectFavicon(data) {
this.options.blog_favicon = data.path
this.options.blog_favicon = encodeURI(data.path)
this.faviconDrawerVisible = false
}
}

View File

@ -218,7 +218,7 @@ export default {
})
},
handleSelectAvatar(data) {
this.user.avatar = data.path
this.user.avatar = encodeURI(data.path)
this.attachmentDrawerVisible = false
},
handleSelectGravatar() {