'CiviPledge', 'translatedName' => ts('CiviPledge'), 'title' => ts('CiviCRM Pledge Engine'), 'search' => 1, 'showActivitiesInCore' => 1, ); } // docs inherited from interface public function getPermissions($getAllUnconditionally = FALSE) { return array( 'access CiviPledge', 'edit pledges', 'delete in CiviPledge', ); } // docs inherited from interface public function getUserDashboardElement() { return array('name' => ts('Pledges'), 'title' => ts('Your Pledge(s)'), // we need to check this permission since you can click on contribution page link for making payment 'perm' => array('make online contributions'), 'weight' => 15, ); } // docs inherited from interface public function registerTab() { return array('title' => ts('Pledges'), 'url' => 'pledge', 'weight' => 25, ); } // docs inherited from interface public function registerAdvancedSearchPane() { return array('title' => ts('Pledges'), 'weight' => 25, ); } // docs inherited from interface public function getActivityTypes() { return NULL; } // add shortcut to Create New public function creatNewShortcut(&$shortCuts) { if (CRM_Core_Permission::check('access CiviPledge') && CRM_Core_Permission::check('edit pledges') ) { $shortCuts = array_merge($shortCuts, array( array('path' => 'civicrm/pledge/add', 'query' => 'reset=1&action=add&context=standalone', 'ref' => 'new-pledge', 'title' => ts('Pledge'), ))); } } }