ignore api calls

This commit is contained in:
CiviWare Solutions 2018-08-30 17:45:23 +01:00
parent 6ac1eaf067
commit 9da3dad3ef
1 changed files with 3 additions and 0 deletions

View File

@ -18,6 +18,9 @@ class CRM_ConstituentsOnly_BAO_Query extends CRM_Contact_BAO_Query_Interface {
* @access public
*/
public function where(&$query) {
if (empty($query->_paramLookup['entryURL'])) {
return;
}
if (CRM_Utils_Array::value('civicrm_contact', $query->_tables)) {
$query->_where[0][] = "( contact_a.do_not_trade IS NULL OR contact_a.do_not_trade = 0)";
}