datatablsカスタマイズ可能レポート固定ヘッダーロック列

1901 ワード

function loading_newbig_composite_table(basic_table_obj){
        var obj = save_newbig_tableHead(basic_table_obj.table_headdata,basic_table_obj.table_show_name,basic_table_obj.table_show_id);
        var tabledata = {data: basic_table_obj.table_bodydata};
        init_newbig_complex_mytable('newbig_complex-thead-tpl','#'+basic_table_obj.table_id+' thead',obj);
        init_newbig_complex_mytable('newbig_complex-tbody-tpl','#'+basic_table_obj.table_id+' tbody',tabledata);
        $("#"+basic_table_obj.table_id).DataTable({
            "paging":false,
            "ordering": false,
            "info": false,
            "scrollX": true,
            "scrollY": 300,
            "scrollCollapse": true,
            "lengthChange":false,
            "searching":false,
            "destroy": true,
            "retrieve": true,
            fixedHeader: true,
            fixedColumns: {
                leftColumns: 1
            },
             "oLanguage": {// 
                 "oAria": {
                     "sSortAscending": " - click/return to sort ascending",
                     "sSortDescending": " - click/return to sort descending"
                 },
                 "sZeroRecords": " , ",
                 "sEmptyTable": " ",
                 "sLoadingRecords": " - ...",
             }
        });
        $('.dataTables_scrollHead,.dataTables_scrollHead,.dataTable,.dataTables_scrollHeadInner').css('width','100%');
        $("#"+basic_table_obj.table_id).perfectScrollbar({
            wheelSpeed: 2,
            wheelPropagation: true,
            minScrollbarLength: 20
        });
    }