bootstrapTable 设置行样式
1、设置字体颜色
function rowStyle(row, index) { var style = {}; style={css:{'color':'#ed5565'}}; return style; }
2、设置行背景颜色
function rowStyle(row, index) { var style = {}; style = {css:{'background-color':'#ed5565'}}; return style; }
注意:
需要在初始化表的时候增加rowStyle 属性
$('#TableId').bootstrapTable({
rowStyle: rowStyle,//通过自定义函数设置行样式
})

浙公网安备 33010602011771号