Used | 1. vue of the pipeline operator ()
// custom filters, through the pipeline operator | change the value of the cell list < EL Table-column- prop = "Status" label = "Status" align = left = "Center" width = "80" > < Template slot-scope = "scope" > {{scope.row.status | the getStatus}} </ Template > </ EL-Table-column > < Script > Export default { Data () { return {......} }, Filters : { getStatus:function(num){ STR the let = '' IF (NUM == . 1 ) { STR = ' enabled ' } the else { STR = ' disabled ' } return STR; } }, Methods: { List ()} ...... {, }, } </ Script >
Reference: Custom filter