<el-table-column label="最低消费" align="center" prop="min" >
<template slot-scope="scope">
<p>{{ "满" + scope.row.min + "减100" }}</p>
</template>
</el-table-column>
也可以列表中两个字段转成整数拼接
<el-table-column label="最低消费" align="center" >
<template slot-scope="scope">
<p>{{ (Number(scope.row.count1)) + (Number(scope.row.count2))}}</p>
</template>
</el-table-column>
<el-table-column label="最低消费" align="center" >
<template slot-scope="scope">
<p>{{ (parseInt(scope.row.count1)) + (parseInt(scope.row.count2))}}</p>
</template>
</el-table-column>
也可以列表中两个字段拼接
<el-table-column label="最低消费" align="center" prop="min+max" >
<template slot-scope="scope">
<p>{{scope.row.min}}{{scope.row.max}}</p>
</template>
</el-table-column>
|