我在 jQuery Datatables 中有一个问题。每次单击排序时都会显示此“正在处理”消息,并且排序是客户端排序。这真的很烦人,因为它看起来像一个闪烁。我怎么能做这样的事情?如果处理时间小于 1 秒,不显示“处理中”消息?
$('#tblUsers').dataTable({
"bDestroy": true,
"bProcessing": true,
"sProcessing": false,
"sAjaxSource": path,
"bFilter": false,
"bLengthChange": false,
"bInfo": false,
"iDisplayLength": 15,
"sPaginationType": "full_numbers",
"aoColumns":
[
{ "mDataProp": "UserName" },
{ "mDataProp": "FirstName" },
{ "mDataProp": "LastName" },
{ "sDefaultContent": "", "fnRender": function (oObj) { return "<a onclick=AssignUser(this,'" + oObj.aData.UserName + "','btnRemove_" + oObj.aData.UserName + "') id='btnAssgin_" + oObj.aData.UserName + "'> Assign User</a>"; }
},
{ "sDefaultContent": "", "fnRender": function (oObj) { return "<a onclick=RemoveUser(this,'" + oObj.aData.UserName + "','btnAssgin_" + oObj.aData.UserName + "') id='btnRemove_" + oObj.aData.UserName + "' disabled='true'>Remove User</a>"; }
}
],
"aoColumnDefs": [
{ "sWidth": "20%", "aTargets": [0] },
{ "sWidth": "20%", "aTargets": [1] },
{ "sWidth": "20%", "aTargets": [2] },
{ "sWidth": "20%", "aTargets": [3] },
{ "sWidth": "20%", "aTargets": [4] }
]
});