Pārlūkot izejas kodu

update file upload url

reghao 2 gadi atpakaļ
vecāks
revīzija
9e5c77ebd2

+ 1 - 1
src/components/upload/PublishVideo.vue

@@ -339,7 +339,7 @@ export default {
           const formData = new FormData()
           formData.append('file', coverFile)
           formData.append('channelId', this.imgData.channelId)
-          fetch(process.env.VUE_APP_OSS_URL, {
+          fetch(this.imgOssUrl, {
             headers: this.imgHeaders,
             method: 'POST',
             credentials: 'include',

+ 1 - 0
src/views/disk/UploadFile.vue

@@ -95,6 +95,7 @@ export default {
     getServerInfo(this.channelId).then(resp => {
       if (resp.code === 0) {
         const resData = resp.data
+        this.ossUrl = resData.ossUrl
         this.options = {
           target: resData.ossUrl,
           chunkSize: resData.maxSize,