elementui 表格 计算属性 scope.row

  <template slot-scope="scope">
          <el-tag :type="formatterhandleStatus(scope.row)" disable-transitions size="small">新TAG</el-tag>
  </template>


computed:{
  formatterhandleStatus(){
     function  formatterhandleTag(val){
          if(val === 1){return "danger"}
      }
   return formatterhandleTag
  }
  
}

本文来自博客园,作者:云霄紫潭,转载请注明原文链接:https://www.cnblogs.com/0520euv/p/15771256.html

原文地址:https://www.cnblogs.com/0520euv/p/15771256.html