Bootstrap

ElementUI中el-table-column的数据格式化方式有两种

①第一种使用:formatter="formatCashDate"方式格式化

<el-table-column property="cashDate" label="" width="140" :formatter="formatCashDate"></el-table-column>
    // 格式化实际回款日期
    formatCashDate(row, column) {
     
    },

②第二种方式

<el-table-column property="cashDate" label="" width="140">
            <template slot-scope="scope">
              {{ formatCashDate(scope.row) }}
            </template>
          </el-table-column>
  // 格式化实际回款日期
    formatCashDate(row) {
     
    },

 

 

 

;