12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667 |
- @{
- Layout = "~/Views/Shared/Main.cshtml";
- }
- <div class="layui-form">
- <div class="layui-col-md3" >
- <div class="layui-inline">
- <div class="layui-form-text">查询</div>
- <input id="search" name="search" class="layui-text" />
- </div>
- </div>
- </div>
- <div id="demo" class="layui-table"></div>
- <script>
- layui.use('table', function () {
- var table = layui.table;
- table.render({
- var datatable=table.render({
- elem: '#demo'
- ,url: '/Point/DriverData' //数据接口
- ,page: true //开启分页
- data: {},
- toolbar:'defaultToolbar',
- cols: [[
- { title: 'APIName', fixed: 'API名称',type:'numbers' },
- { field: 'Content', title: 'API备注', align: 'center' },
- { field: 'DelayTime', title: '超时时间', align: 'center' },
- { field: 'APIType', title: 'API类型', align: 'center' },
- { field: 'APIMethod', title: 'API方法', align: 'center' },
- { field: 'Params', title: '点位数', align: 'center' },
-
- { field: 'APIKey', title: '操作', align: 'center' template:"" }
- ]]
- })
- })
- window.tablereload = function () {
- table.reload('demo', {
- //where: { // 传递数据异步请求时携带的字段
- // aaa: '111',
- // bbb: '222'
- // //…
- //},
- //height: 1000 // 重设高度
- });
- }
- //$.post("/index/select", function (myg) {//印证有没有获取数据
- // console.log(myg);
- //})
- </script>
|