<el-table-column prop="businessState" label="当前状态" width="250px" show-overflow-tooltip align="center"> <template scope="scope"> <p v-if="scope.row.businessState=='0'">配置中</p> <p v-if="scope.row.businessState=='1'">发布</p> <p v-if="scope.row.businessState=='2'">失效</p> </template> </el-table-column>
转自本站大佬,大佬牛逼,element能用<v-if>解决太多问题了!