MS_Addon_Invitation

Add-On controller for: Invitations.

Defined (1)

The class is defined in the following location(s).

/app/addon/invitation/class-ms-addon-invitation.php  
  1. class MS_Addon_Invitation extends MS_Addon { 
  2.  
  3. /** 
  4. * The Add-on ID 
  5. * @since 1.0.0 
  6. */ 
  7. const ID = 'invitation'; 
  8.  
  9. /** 
  10. * Checks if the current Add-on is enabled 
  11. * @since 1.0.0 
  12. * @return bool 
  13. */ 
  14. static public function is_active() { 
  15. return false; 
  16.  
  17. /** 
  18. * Returns the Add-on ID (self::ID). 
  19. * @since 1.0.1.0 
  20. * @return string 
  21. */ 
  22. public function get_id() { 
  23. return self::ID; 
  24.  
  25. /** 
  26. * Initializes the Add-on. Always executed. 
  27. * @since 1.0.0 
  28. */ 
  29. public function init() { 
  30. MS_Model_Addon::disable( self::ID ); 
  31.  
  32. /** 
  33. * Registers the Add-On 
  34. * @since 1.0.0 
  35. * @param array $list The Add-Ons list. 
  36. * @return array The updated Add-Ons list. 
  37. */ 
  38. public function register( $list ) { 
  39. $list[ self::ID ] = (object) array( 
  40. 'name' => __( 'Invitation Codes', 'membership2' ),  
  41. 'description' => __( 'Users need an invitation code to subscribe to a membership.', 'membership2' ),  
  42. 'icon' => 'wpmui-fa wpmui-fa-unlock-alt',  
  43. 'action' => array( __( 'Pro Version', 'membership2' ) ),  
  44. ); 
  45.  
  46. return $list; 
  47.