zoukankan      html  css  js  c++  java
  • layui的table.render使用

     var tableIns = table.render({
            elem: '#recordList',  // 指向页面组件id
            where: { UId: 1 },  // 传递参数
            url: '/Manager/GetList/',  // 异步获取数据
            cellMinWidth: 95,
            page: true,  // 开启分页
            height: "full-125",
            limits: [10, 15, 20, 25],
            limit: 10,   // 每页条数
            id: "recordListTable",  // 本表id
            cols: [[
                { type: "checkbox", fixed: "left",  50 },
                { field: "ID", title: 'ID',  120, minWidth: 90, align: "center" },
                { field: 'Time', title: '日期', minWidth: 180, align: "center" },
                { field: 'Name', title: '名字', minWidth: 180, align: "center" },
                { field: 'Content', title: '内容', minWidth: 400, align: 'center' },
                { field: 'IsLock', title: '是否锁定', minWidth: 100, fixed: "right", align: "center", templet: '#IsLock' },
                { title: '操作', minWidth: 150, templet: '#recordListBar', fixed: "right", align: "center" }
            ]],
    done: function () { $("[data-field='ID']").css('display','none'); } // 列隐藏 });
    365个夜晚,我希望做到两天更一篇博客。加油,小白!
  • 相关阅读:
    几种常见排序算法
    62.Android之各分辨率定义的图片规格
    MVC
    EasyUI datebox 只读和取值
    WebForm带有图片的验证码
    WebForm水印照片
    ajax完整结构
    jquery简单动画
    webform数据导出
    WebForm 发送邮箱
  • 原文地址:https://www.cnblogs.com/qq2806933146xiaobai/p/14993370.html
Copyright © 2011-2022 走看看