diff --git a/src/components/quill/index.vue b/src/components/quill/index.vue index 1d7c558..c8e58c6 100644 --- a/src/components/quill/index.vue +++ b/src/components/quill/index.vue @@ -180,11 +180,11 @@ export default { // 获取富文本组件实例 let quill = this.Quill; // 如果上传成功 - if (res.filesResult.fileUrl) { + if (res.data.filesResult.fileUrl) { // 获取光标所在位置 let length = quill.getSelection().index; // 插入图片,res为服务器返回的图片链接地址 - quill.insertEmbed(length, "image", res.filesResult.fileUrl); + quill.insertEmbed(length, "image", res.data.filesResult.fileUrl); // 调整光标到最后 quill.setSelection(length + 1); } else { diff --git a/src/pages/course/courseManagement/add.vue b/src/pages/course/courseManagement/add.vue index debc91b..934a5f9 100644 --- a/src/pages/course/courseManagement/add.vue +++ b/src/pages/course/courseManagement/add.vue @@ -170,7 +170,7 @@ export default { util.warningMsg("当前限制选择 1 个文件,如需更换,请删除上一个文件再重新选择!"); }, uploadSuccess(res, file, fileList) { - this.coverUrl = res.filesResult.fileUrl; + this.coverUrl = res.data.filesResult.fileUrl; // this.uploadList.push({ name: file.name, url: response.message.fileUrl }); }, uploadError(err, file, fileList) { diff --git a/src/pages/course/courseManagement/contentSettings.vue b/src/pages/course/courseManagement/contentSettings.vue index 3c2f5dd..1da3ca3 100644 --- a/src/pages/course/courseManagement/contentSettings.vue +++ b/src/pages/course/courseManagement/contentSettings.vue @@ -310,10 +310,10 @@ export default { }, uploadSuccess(res, file, fileList) { this.uploading = false; - this.fileId = res.filesResult.fileId; - this.fileType = res.filesResult.fileType; - this.fileUrl = res.filesResult.fileUrl; - this.fileName = res.filesResult.ossFileName; + this.fileId = res.data.filesResult.fileId; + this.fileType = res.data.filesResult.fileType; + this.fileUrl = res.data.filesResult.fileUrl; + this.fileName = res.data.filesResult.ossFileName; }, uploadError(err, file, fileList) { this.$message({ diff --git a/src/pages/information/contentManage/addArticle.vue b/src/pages/information/contentManage/addArticle.vue index 0f7b1c2..5a1d07b 100644 --- a/src/pages/information/contentManage/addArticle.vue +++ b/src/pages/information/contentManage/addArticle.vue @@ -157,7 +157,7 @@ export default { }).catch(res => { }); } - this.coverUrl = res.filesResult.fileUrl; + this.coverUrl = res.data.filesResult.fileUrl; }, uploadError(err, file, fileList) { this.$message({ diff --git a/src/pages/match/add.vue b/src/pages/match/add.vue index be6b545..29730da 100644 --- a/src/pages/match/add.vue +++ b/src/pages/match/add.vue @@ -270,7 +270,7 @@ export default { }).catch(res => { }); } - this.coverUrl = res.filesResult.fileUrl; + this.coverUrl = res.data.filesResult.fileUrl; }, uploadLgSuccess(res, file, fileList) { if (this.carouselUrl) { @@ -279,7 +279,7 @@ export default { }).catch(res => { }); } - this.carouselUrl = res.filesResult.fileUrl; + this.carouselUrl = res.data.filesResult.fileUrl; }, uploadError(err, file, fileList) { this.$message({ diff --git a/src/pages/match/manage/matchDetail.vue b/src/pages/match/manage/matchDetail.vue index ca3ac6e..dabbf69 100644 --- a/src/pages/match/manage/matchDetail.vue +++ b/src/pages/match/manage/matchDetail.vue @@ -243,7 +243,7 @@ export default { }).catch(res => { }); } - this.coverUrl = res.filesResult.fileUrl; + this.coverUrl = res.data.filesResult.fileUrl; }, uploadLgSuccess(res, file, fileList) { if (this.carouselUrl) { @@ -252,7 +252,7 @@ export default { }).catch(res => { }); } - this.carouselUrl = res.filesResult.fileUrl; + this.carouselUrl = res.data.filesResult.fileUrl; }, uploadError(err, file, fileList) { this.$message({