9 列のデータテーブルがあり、列 [0] と [8] は非表示になっています。次に、列 [7] と [8] が 1 つの列にマージされます (以下のコードを参照)。
私が苦労しているのは、列を非表示にするときに ColVis プラグインを使用することです。列 [7] と [8] のマージが台無しになります。
それが理にかなっていることを願っています。どんな助けでも大歓迎です。
var $buTable= $("#business_table").dataTable( {
"oLanguage": {
"sSearch": "Filter:"
},
"bProcessing": true,
"bServerSide": true,
"sAjaxSource": "scripts/business_serverside.php",
"iDisplayLength": 10,
"bJQueryUI": false,
"sPaginationType": "scrolling",
"sDom": '<"clear"><"top"CTilr<"clear">pt>',
"aoColumns": [
{"bVisible":false},
{"bVisible":true},
{"bVisible":true},
{"bVisible":true},
{"bVisible":true},
{"bVisible":true},
{"bVisible":true},
{"bVisible":true},
{"bVisible":false}
],
"fnRowCallback": function( nRow, aData, iDisplayIndex ) {
$('td:eq(6)', nRow).html(''+ aData[7] +' '+ aData[8] +'');
},
"oTableTools": {
"sSwfPath": "swf/copy_csv_xls_pdf.swf"
},
"oColVis": {
"activate": "mouseover",
"aiExclude": [0,8]
}
}).columnFilter({
aoColumns: [
{ type: "select"},
{ type: "text" },
{ type: "select" },
{ type: "select"},
{ type: "text"},
{ type: "text"},
{ type: "select"},
{ type: "text"}
]
});