From: Coleman Watts Date: Tue, 16 Jun 2015 18:36:28 +0000 (-0400) Subject: CRM-16512 - Hide dashboard related contact table for users without 'view my contact' X-Git-Url: https://vcs.fsf.org/?a=commitdiff_plain;h=bb36d17afa8cdfdbbdd44671665e457e88fe1f1c;p=civicrm-core.git CRM-16512 - Hide dashboard related contact table for users without 'view my contact' --- diff --git a/CRM/Contact/Page/View/UserDashBoard.php b/CRM/Contact/Page/View/UserDashBoard.php index fb3cf35e79..f10bb04ae3 100644 --- a/CRM/Contact/Page/View/UserDashBoard.php +++ b/CRM/Contact/Page/View/UserDashBoard.php @@ -146,7 +146,8 @@ class CRM_Contact_Page_View_UserDashBoard extends CRM_Core_Page { } } - if (!empty($this->_userOptions['Permissioned Orgs'])) { + // CRM-16512 - Hide related contact table if user lacks permission to view self + if (!empty($this->_userOptions['Permissioned Orgs']) && CRM_Core_Permission::check('view my contact')) { $dashboardElements[] = array( 'class' => 'crm-dashboard-permissionedOrgs', 'templatePath' => 'CRM/Contact/Page/View/RelationshipSelector.tpl',