Layui table

        table.render({
            elem: '#LAY-app-content-tags'
            , url: "/api/services/app/BimAttribute/GetAllForLayui"
            , parseData: function (res) {//自定义解析返回的数据
                return {
                    "code": res.success, //解析接口状态
                    "msg": res.error, //解析提示文本
                    "count": res.result.count, //解析数据长度
                    "data": res.result.data //解析数据列表
                };
            }
            , limit: 10
            , limits: [10, 20, 30]
            , cols: [[
                { field: 'id', title: 'ID', hide: false }
                , { field: 'componentCode', title: app.localize("ComponentCode"), sort: true }
                , { field: 'concretValue', title: app.localize("ConcretValue") }
                , { field: 'identifier', title: app.localize("Identifier"), sort: true }               
            ]]
            , page: true
            , response: {
                statusCode: true //规定成功的状态码,默认:0
            }
        });
原文地址:https://www.cnblogs.com/guxingy/p/12119820.html