| 1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465 |
- $(document).ready(function() {
- GetBNewsList();
- //getClient();
- //顶部hover
- $('.topbarWx').hover(function() {
- $('.topbarWx .topbarWx-box').css('left', $(this).offset().left);
- });
- $('.topbarClient').hover(function() {
- $('.topbarClient .topbarClient-box').css('left', $(this).offset().left);
- });
- });
- function GetBNewsList() {
- layui.use('table', function() {
- var table = layui.table;
- //方法级渲染
- table.render({
- elem: '#list',
- url: huayi.config.callcenter_url + "Web/GetWebNewsList",
- method: 'get', //如果无需自定义HTTP类型,可不加该参数
- skin: 'row', //line (行边框风格) row (列边框风格) nob (无边框风格)
- even: true, //开启隔行背景
- where: {
- type: 3
- },
- limit: 10,
- limits: [10],
- request: {
- pageName: 'page' //页码的参数名称,默认:page
- ,
- limitName: 'pagesize' //每页数据量的参数名,默认:limit
- },
- response: {
- statusName: 'state', //状态字段名称
- statusCode: 'success', //状态字段成功值
- countName: 'total' //数据总数的字段名称,默认:count
- ,
- dataName: 'rows' //数据列表的字段名称,默认:data
- },
- cols: [
- [{
- field: 'bt',
- minWidth: 150,
- title: '信息主题',
- templet: '#switchTpl'
- }, {
- field: 'sj',
- width: 220,
- title: '日期'
- }]
- ],
- page: true
- });
- });
- }
- function ComContent2(val, row) {
- return '<div class="imgs" >' +
- '<a href="PG.html?id=' + row.id + '"> ' + val + '</a>' +
- '</div>';
- }
|