mirror of
https://gitee.com/beecue/fastbee.git
synced 2025-12-18 08:55:53 +08:00
图片和文件上传优化
This commit is contained in:
@@ -70,7 +70,7 @@ export default {
|
||||
data() {
|
||||
return {
|
||||
baseUrl: process.env.VUE_APP_BASE_API,
|
||||
uploadFileUrl: process.env.VUE_APP_BASE_API + "/iot/tool/upload", // 上传的图片服务器地址
|
||||
uploadFileUrl: process.env.VUE_APP_BASE_API + "/iot/tool/upload", // 上传文件服务器地址
|
||||
headers: {
|
||||
Authorization: "Bearer " + getToken(),
|
||||
},
|
||||
|
||||
@@ -124,7 +124,7 @@ export default {
|
||||
},
|
||||
// 上传成功回调
|
||||
handleUploadSuccess(res) {
|
||||
this.fileList.push({ name: res.fileName, url: process.env.VUE_APP_BASE_API + "/iot/tool/download?fileName="+res.fileName });
|
||||
this.fileList.push({ name: res.fileName, url: process.env.VUE_APP_BASE_API +res.fileName });
|
||||
this.$emit("input", this.listToString(this.fileList));
|
||||
this.loading.close();
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user