X-Git-Url: https://vcs.fsf.org/?a=blobdiff_plain;f=CRM%2FMember%2FInfo.php;h=2aba1062d5e3df3de7cc1b1613bdabc49f90e055;hb=6a74571fd3f5a9140d1de6533f9cb91e26e9c826;hp=c1136435d0b484327d9a8c3ea8d8028cd66c2443;hpb=0554664067cdf3fb0f8e9210481a3346b905394a;p=civicrm-core.git diff --git a/CRM/Member/Info.php b/CRM/Member/Info.php index c1136435d0..2aba1062d5 100644 --- a/CRM/Member/Info.php +++ b/CRM/Member/Info.php @@ -41,6 +41,18 @@ class CRM_Member_Info extends CRM_Core_Component_Info { protected $keyword = 'member'; // docs inherited from interface + /** + * Provides base information about the component. + * Needs to be implemented in component's information + * class. + * + * @return array collection of required component settings + * @access public + * + */ + /** + * @return array + */ public function getInfo() { return array( 'name' => 'CiviMember', @@ -53,6 +65,24 @@ class CRM_Member_Info extends CRM_Core_Component_Info { // docs inherited from interface + /** + * Provides permissions that are used by component. + * Needs to be implemented in component's information + * class. + * + * NOTE: if using conditionally permission return, + * implementation of $getAllUnconditionally is required. + * + * @param bool $getAllUnconditionally + * + * @return array|null collection of permissions, null if none + * @access public + */ + /** + * @param bool $getAllUnconditionally + * + * @return array|null + */ public function getPermissions($getAllUnconditionally = FALSE) { return array( 'access CiviMember', @@ -62,6 +92,18 @@ class CRM_Member_Info extends CRM_Core_Component_Info { } // docs inherited from interface + /** + * Provides information about user dashboard element + * offered by this component. + * + * @return array|null collection of required dashboard settings, + * null if no element offered + * @access public + * + */ + /** + * @return array|null + */ public function getUserDashboardElement() { return array('name' => ts('Memberships'), 'title' => ts('Your Membership(s)'), @@ -74,6 +116,18 @@ class CRM_Member_Info extends CRM_Core_Component_Info { } // docs inherited from interface + /** + * Provides information about user dashboard element + * offered by this component. + * + * @return array|null collection of required dashboard settings, + * null if no element offered + * @access public + * + */ + /** + * @return array|null + */ public function registerTab() { return array('title' => ts('Memberships'), 'url' => 'membership', @@ -82,6 +136,18 @@ class CRM_Member_Info extends CRM_Core_Component_Info { } // docs inherited from interface + /** + * Provides information about advanced search pane + * offered by this component. + * + * @return array|null collection of required pane settings, + * null if no element offered + * @access public + * + */ + /** + * @return array|null + */ public function registerAdvancedSearchPane() { return array('title' => ts('Memberships'), 'weight' => 30, @@ -89,11 +155,28 @@ class CRM_Member_Info extends CRM_Core_Component_Info { } // docs inherited from interface + /** + * Provides potential activity types that this + * component might want to register in activity history. + * Needs to be implemented in component's information + * class. + * + * @return array|null collection of activity types + * @access public + * + */ + /** + * @return array|null + */ public function getActivityTypes() { return NULL; } // add shortcut to Create New + /** + * @param $shortCuts + * @param $newCredit + */ public function creatNewShortcut(&$shortCuts, $newCredit) { if (CRM_Core_Permission::check('access CiviMember') && CRM_Core_Permission::check('edit memberships')