可以通过传参的方式获取
template:
<el-table-column prop="flowDirection" label="流向" width="80">
<template slot-scope="scope">
<div>
{{scope.row.flowDirection | formtaLab(labList)}}
</div>
</template>
</el-table-column>
filters: {
formtaLab(item, labList) {
console.log(item, labList, "==>>");
let str = "默认流向";
labList.forEach((el) => {
if (el.code == item) {
str = el.name;
}
});
return str;
},
},