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给行怎么加背景色的详细内容,更多文章请关注木庄网络博客

返回前面的内容

相关阅读 >>

bootstrap如何响应式布局

当 position:sticky 遇到 bootstrap 浮动布局时候的踩坑记录

bootstrap模态框加滚动条

浅谈bootstrap3中的下拉菜单事件

为什么前端不用bootstrap

用npm下载bootstrap后怎么引入

rocketbootstrap是什么

bootstrap中fonts怎么引用

bootstrap框架的好处

bootstrap 为什么只能默认12列

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




打赏

取消

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

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

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

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

评论

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