WYSIJA_module_statistics

The MailPoet Newsletters WYSIJA module statistics class.

Defined (1)

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

/core/module/statistics.php  
  1. class WYSIJA_module_statistics extends WYSIJA_module{ 
  2. const GROUP_BY_YEAR = 1; 
  3. const GROUP_BY_MONTH = 2; 
  4. const GROUP_BY_DATE = 3; 
  5. const GROUP_BY_HOUR = 4; 
  6. const GROUP_BY_MINUTE = 5; 
  7.  
  8. const ORDER_BY_SENT = 1; 
  9. const ORDER_BY_OPEN = 2; 
  10. const ORDER_BY_CLICK = 3; 
  11. const ORDER_BY_UNSUBSCRIBE = 4; 
  12.  
  13. const ORDER_DIRECTION_ASC = 1; 
  14. const ORDER_DIRECTION_DESC = 2; 
  15.  
  16. const SWITCHING_DATE_TO_MONTH_THRESHOLD = 90;// if the days between FROM and TO is greater than this value, we will group data by month instead of by date. Useful for charts. 
  17.  
  18. const DEFAULT_TOP_RECORDS = 5; // default number of how many first records we should retrieve 
  19.  
  20. public function __construct() { 
  21. parent::__construct(); 
  22. $this->data['messages'] = $this->init_messages(); 
  23.  
  24. protected function init_messages() { 
  25. return array( 
  26. 'data_not_available' => __("There's no stats to load!", WYSIJA) 
  27. );