diff --git a/src/components/ShowFile/ShowFile.vue b/src/components/ShowFile/ShowFile.vue index c637bc8..5b4fc9a 100644 --- a/src/components/ShowFile/ShowFile.vue +++ b/src/components/ShowFile/ShowFile.vue @@ -2415,7 +2415,7 @@ export default { return } api.rename({ - newFileName: newFileName, + newFileName: encodeURI(newFileName), username: this.$store.state.user.name, id: row.id }).then(res => { diff --git a/src/components/preview/SimTextPreview.vue b/src/components/preview/SimTextPreview.vue index 08f6aeb..09c184e 100644 --- a/src/components/preview/SimTextPreview.vue +++ b/src/components/preview/SimTextPreview.vue @@ -684,7 +684,7 @@ update(value,path,index) { this.updating = true markdownApi.editMarkdownByPath({ - relativePath: path, + relativePath: encodeURI(path), userId: this.$store.state.user.userId, username: this.$store.state.user.name, contentText: value diff --git a/src/views/home/mobile/index.vue b/src/views/home/mobile/index.vue index 7c1cf1f..65f081e 100644 --- a/src/views/home/mobile/index.vue +++ b/src/views/home/mobile/index.vue @@ -584,7 +584,7 @@ export default { } api.rename({ - newFileName: newFileName, + newFileName: encodeURI(newFileName), username: this.$store.state.user.name, id: row.id }).then(res => {