table.render({
elem: '#list' ,
height: 'full-300' ,
response: {statusCode: 200} ,
url: ""//数据接口 ,
method: 'GET' /* 使用什么协议,默认的是GET */
, loading: true //请求数据时,是否显示loading ,
cols: [[ //表头
{checkbox: true, fixed: true, width: "5%"} ,
{title: '序号', type: "numbers", align: 'center', width: "7%"} ,
{field: 'username', title: '用户名', align: 'center', width: "10%"} ,
{field: 'password', title: '密码', align: 'center', width: "10%", sort: true} ,
{field: 'phone', title: '手机号', align: 'center', width: "10%"} ,
{field: 'email', title: '邮箱', align: 'center', width: "10%", sort: true} ,
{field: 'belong_id', title: '权限', align: 'center', width: "10%"} ,
{field: 'role', title: '角色名', align: 'center', width: "10%", sort: true} ,
{fixed: 'right', title: '操作', width: "28%", align: 'center', toolbar: '#barlist'} ]]//操作栏的操作使用工具