----------------------------------------
* CRM-14201: Contact Relationships tab needs pagination
http://issues.civicrm.org/jira/browse/CRM-14201
// Call native refresh method on ajax datatables
if ($.fn.DataTable.fnIsDataTable($table[0]) && $table.dataTable().fnSettings().sAjaxSource) {
$table.unblock().dataTable().fnDraw();
+
+ // incase of more than 1 datatables on same page, refresh remaining datatables
+ $('table.dataTable').each(function () {
+ var currentTable = $(this);
+ if (currentTable.prop('id') != $table.prop('id')) {
+ currentTable.block();
+ if ($.fn.DataTable.fnIsDataTable(currentTable[0]) && currentTable.dataTable().fnSettings().sAjaxSource) {
+ $(this).unblock().dataTable().fnDraw();
+ }
+ }
+ });
}
// Otherwise refresh the content area using crmSnippet
else {