Browse Source

商品属性图片上传修改

master
hupeng 5 years ago
parent
commit
8c32b8a1d2
  1. 6
      src/components/pic-upload-two/index.vue

6
src/components/pic-upload-two/index.vue

@ -2,7 +2,7 @@
<div>
<el-upload
class="pic-uploader-component"
:action="qiNiuUploadApi"
:action="uploadApi"
:headers="headers"
:show-file-list="false"
:on-success="handleUploadSuccess"
@ -34,14 +34,14 @@ export default {
},
computed: {
...mapGetters([
'qiNiuUploadApi'
'uploadApi'
])
},
methods: {
//
handleUploadSuccess(response, file, fileList) {
console.log(file)
this.$emit('input', file.response.data[0])
this.$emit('input', file.response.link)
},
//
beforeAvatarUpload(file) {

Loading…
Cancel
Save