zoukankan      html  css  js  c++  java
  • bootstrap-table 回显选中行,行样式

    {
        filed:'status',
        checkbox:true,
        formatter:function(value,row,index){
            if (row.status == 1)  //根据行里字段判断是否选中
                return {
                    checked : true//设置选中
                };
            return value;
        }
    
    }

    行样式:

      rowStyle: function (row, index) {
                    //这里有5个取值代表5中颜色['active', 'success', 'info', 'warning', 'danger'];
                    var strclass = "";
                    if (row.name == "删除环境") {
                        strclass = 'danger';//还有一个active
                    }
                    else if (row.name == "新增环境") {
                        strclass = 'success';
                    }
                    else {
                        return {};
                    }
                    return { classes: strclass }
                },
  • 相关阅读:
    通过kinaba对es进行crud
    安装启动kibana
    es安装启动
    IP网络层
    Java 高级文本处理
    django17
    邮件问题
    django16
    django15
    django14
  • 原文地址:https://www.cnblogs.com/asker009/p/9617677.html
Copyright © 2011-2022 走看看