$contactRelationships[$relationshipId]['phone'] = $values['phone'];
$contactRelationships[$relationshipId]['links'] = $values['action'];
$contactRelationships[$relationshipId]['id'] = $values['id'];
+ $contactRelationships[$relationshipId]['is_active'] = $values['is_active'];
}
}
return $contactRelationships;
7 => 'phone',
8 => 'links',
9 => '',
+ 10 => '',
);
$sEcho = CRM_Utils_Type::escape($_REQUEST['sEcho'], 'Integer');
'phone',
'links',
'id',
+ 'is_active',
);
echo CRM_Utils_JSON::encodeDataTableSelector($relationships, $sEcho, $iTotal, $iFilteredTotal, $selectorElements);
{sClass: 'crm-contact-relationship-email'},
{sClass: 'crm-contact-relationship-phone'},
{sClass: 'crm-contact-relationship-links', bSortable: false},
+ {sClass: 'hiddenElement', bSortable: false},
{sClass: 'hiddenElement', bSortable: false}
],
"bProcessing": true,
{/literal}{/if}{literal}
},
"fnRowCallback": function( nRow, aData, iDisplayIndex, iDisplayIndexFull) {
- cj(nRow).addClass('crm-entity');
cj(nRow).attr('id', 'relationship-'+ aData[9]);
+ if (aData[10] == 0) {
+ cj(nRow).addClass('crm-entity disabled');
+ }
+ else {
+ cj(nRow).addClass('crm-entity');
+ }
}
});
}