直播平臺搭建,el-form上傳成功後或其他把提示關閉

zhibo系統開發發表於2023-02-20

直播平臺搭建,el-form上傳成功後或其他把提示關閉

<el-form
                ref="perForm"
                :rules="perFormRules"
                :model="perForm"
                label-width="120px"
                class="perForm"
              >
 
<el-upload
                          class="avatar-uploader"
                          action="#"
                          accept="image/jpeg, image/png"
                          ref="upload"
                          :limit="1"
                          :file-list.sync="fileList"
                          :http-request="httpRequest"
                          :on-success="handleAvatarSuccess"
                          :before-upload="beforeAvatarUpload"
                          :on-remove="removeFile"
                        >
 
  // 圖片上傳成功事件
    handleAvatarSuccess(url) {
      this.imageUrl = url;
      this.$refs['perForm'].validateField('headImg')
      // console.log('圖片上傳成功',this.perFormRules.headImg[0].required);
    },

 以上就是 直播平臺搭建,el-form上傳成功後或其他把提示關閉,更多內容歡迎關注之後的文章


來自 “ ITPUB部落格 ” ,連結:http://blog.itpub.net/69978258/viewspace-2935972/,如需轉載,請註明出處,否則將追究法律責任。

相關文章