From: yashodha Date: Thu, 7 Apr 2016 06:12:26 +0000 (+0530) Subject: CRM-18372 : dashboard notice error X-Git-Url: https://vcs.fsf.org/?a=commitdiff_plain;h=6da0be4dc09637d4b48fe820928f9f1f31ef5035;p=civicrm-core.git CRM-18372 : dashboard notice error ---------------------------------------- * CRM-18372: dashboard notice error https://issues.civicrm.org/jira/browse/CRM-18372 --- diff --git a/CRM/PCP/BAO/PCP.php b/CRM/PCP/BAO/PCP.php index 9f3d8336a0..882631e71c 100644 --- a/CRM/PCP/BAO/PCP.php +++ b/CRM/PCP/BAO/PCP.php @@ -118,6 +118,7 @@ WHERE civicrm_pcp.contact_id = civicrm_contact.id $query = " SELECT * FROM civicrm_pcp pcp +LEFT JOIN civicrm_pcp_block block ON block.id = pcp.pcp_block_id WHERE pcp.is_active = 1 AND pcp.contact_id = %1 ORDER BY page_type, page_id"; @@ -135,6 +136,8 @@ ORDER BY page_type, page_id"; $approved = CRM_Utils_Array::key('Approved', $pcpStatus); while ($pcpInfoDao->fetch()) { +//crm_core_error::Debug($pcpInfoDao); + $mask = $hide; if ($links) { $replace = array( @@ -149,7 +152,7 @@ ORDER BY page_type, page_id"; if ($pcpInfoDao->status_id != $approved || $pcpInfoDao->is_active != 1) { $class = 'disabled'; - if (!$pcpInfoDao->tellfriend) { + if (!$pcpInfoDao->is_tellfriend_enabled) { $mask -= CRM_Core_Action::DETACH; } }