<el-form-item label="活动图片" prop="fileList">
<cos-el-upload
ref="upload"
:action="uploadUrl"
:headers="{Authorization:tokenId}"
:on-change="uploadChange"
:on-remove="uploadRemove"
:on-preview="handlePictureCardPreview" //点击放大图片功能
****list-type="picture-card"****
:on-success="handleAvatarSuccess"
:on-error="handleAvatarError"
:before-upload="beforeUpload"
accept=".jpg, .jpeg, .png, .gif, .bmp"
:limit="1"
:file-list="fileList"
>
<i class="el-icon-plus"></i>
</cos-el-upload>
<el-dialog :visible.sync="dialogVisible" :append-to-body="true"> **去掉遮罩层**
<img width="100%" :src="dialogImageUrl" alt />
</el-dialog>
</el-form-item>
**handlePictureCardPreview(file) {
this.dialogImageUrl = file.url;
this.dialogVisible = true;
},**