diff --git a/public/index.html b/public/index.html
index fe4951b..87bfe8c 100644
--- a/public/index.html
+++ b/public/index.html
@@ -7,7 +7,7 @@
<%= htmlWebpackPlugin.options.title %>
diff --git a/src/components/mul-pic-upload/index.vue b/src/components/mul-pic-upload/index.vue
index 4e0f127..663c0f1 100644
--- a/src/components/mul-pic-upload/index.vue
+++ b/src/components/mul-pic-upload/index.vue
@@ -49,7 +49,10 @@
// 图片上传
handleUploadSuccess (response, file, fileList) {
let pics = fileList.map(file => {
- return file.response
+ if (typeof file.response === 'string') {
+ return file.response
+ }
+ return file.response.data
}).join(',')
this.$emit('input', pics)
},
@@ -67,7 +70,10 @@
},
handleRemove (file, fileList) {
let pics = fileList.map(file => {
- return file.response
+ if (typeof file.response === 'string') {
+ return file.response
+ }
+ return file.response.data
}).join(',')
this.$emit('input', pics)
},
diff --git a/src/components/pic-upload/index.vue b/src/components/pic-upload/index.vue
index 93259df..46deb84 100644
--- a/src/components/pic-upload/index.vue
+++ b/src/components/pic-upload/index.vue
@@ -29,7 +29,7 @@
methods: {
// 图片上传
handleUploadSuccess (response, file, fileList) {
- this.$emit('input', file.response)
+ this.$emit('input', file.response.data)
},
// 限制图片上传大小
beforeAvatarUpload (file) {