There are two ways to format the data of el-table-column in ElementUI

①The first method is formatted using: formatter="formatCashDate"

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

②The second way

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

 

 

 

Guess you like

Origin blog.csdn.net/kobe_IT/article/details/130222016