我正在使用jquery datatable插件在jquery UI对话框中显示一个表.下面是我打电话来绘制表格的函数.
function listPtCharges(filter){
var chgTable;
chgTable =
$('#chargeTable').dataTable({
"bJQueryUI": true,
"bDestroy": true,
"sDom": 'tT',
"bSort": false,
"bAutoWidth": false,
"sAjaxSource": "/ajax/ptchglist.php",
"sAjaxDataProp": "Records",
"fnServerData": function ( sSource, aoData, fnCallback ) {
aoData.push( { "name": "acctno", "value": $("#curAcctno").val() } );
aoData.push( { "name": "ins_id", "value": $("#ins_id").val() } );
aoData.push( { "name": "filter", "value": filter } );
$.ajax( {
"dataType" : 'json',
"type" : "POST",
"url" : sSource,
"data" : aoData,
"success" : fnCallback
} );
} ,
"aoColumns":
[
{"bVisible":false}, …Run Code Online (Sandbox Code Playgroud)