<el-table-column header-align="center" align="center" width="150" label=" 商品副标题">
<template slot-scope="scope">
<el-tooltip placement="top" effect="light">
<div slot="content">
{{ scope.row.skuSubtitle }}
</div>
<span>
{{ scope.row.skuSubtitle.length > 10 ? scope.row.skuSubtitle.substr(0, 7) + '...' : scope.row.skuSubtitle }}
</span>
</el-tooltip>
</template>
</el-table-column>
vue判断字符长度,超出部分...显示
最新推荐文章于 2024-05-19 20:18:26 发布