bootstrap table给行怎么加背景色


当前第2页 返回上一页

1

2

3

4

5

6

7

8

9

function rowStyle(row, index) {

    var classes = ['active', 'success', 'info', 'warning', 'danger'];

    if (index % 2 === 0 && index / 2 < classes.length) {

        return {

            classes: classes[index / 2]

        };

    }

    return {};

}

bootstrapTable设置行样式(背景颜色)函数2:调用自定义样式设置指定行的字体颜色

1

2

3

4

5

function rowStyle(row, index) {

    var style = {};           

    style={css:{'color':'#ed5565'}};              

    return style;

}

相关推荐:《bootstrap教程》

以上就是bootstrap table给行怎么加背景色的详细内容,更多文章请关注木庄网络博客

返回前面的内容

相关阅读 >>

less百行代码实现bootstrap栅格布局

bootstrap怎么添加背景图片

bootstrap4.5栅格系统的任意列问题怎么解决?

浅谈bootstrap中处理树列表条件和查询条件的方法

bootstrap怎么实现圆角边框

bootstrap如何响应式布局

怎么引入bootstrap

bootstrap双击事件怎么写

bootstrap怎么处理缓存问题

有必要学bootstrap

更多相关阅读请进入《bootstrap》频道 >>




打赏

取消

感谢您的支持,我会继续努力的!

扫码支持
扫码打赏,您说多少就多少

打开支付宝扫一扫,即可进行扫码打赏哦

分享从这里开始,精彩与您同在

评论

管理员已关闭评论功能...