init() protected method

protected init ( )
 protected function init()
 {
     parent::init();
     $this->action = 'get';
     $this->name = Piwik::translate('General_AbandonedCarts');
     $this->processedMetrics = array('avg_order_revenue');
     $this->order = 15;
     $this->metrics = array('nb_conversions', 'conversion_rate', 'revenue', 'items');
     $this->parameters = array('idGoal' => Piwik::LABEL_ID_GOAL_IS_ECOMMERCE_CART);
 }
 protected function init()
 {
     parent::init();
     $this->action = 'get';
     $this->name = Piwik::translate('General_EcommerceOrders');
     $this->processedMetrics = array('avg_order_revenue');
     $this->order = 10;
     $this->metrics = array('nb_conversions', 'nb_visits_converted', 'conversion_rate', 'revenue', 'revenue_subtotal', 'revenue_tax', 'revenue_shipping', 'revenue_discount');
     $this->parameters = array('idGoal' => Piwik::LABEL_ID_GOAL_IS_ECOMMERCE_ORDER);
 }
 protected function init()
 {
     parent::init();
     $this->action = 'getDaysToConversion';
     $this->name = Piwik::translate('General_EcommerceOrders') . ' - ' . Piwik::translate('Goals_DaysToConv');
     $this->dimension = new DaysToConversion();
     $this->constantRowsCount = true;
     $this->processedMetrics = false;
     $this->metrics = array('nb_conversions');
     $this->order = 12;
     $this->parameters = array('idGoal' => Piwik::LABEL_ID_GOAL_IS_ECOMMERCE_ORDER);
 }
 protected function init()
 {
     parent::init();
     $this->action = 'getVisitsUntilConversion';
     $this->name = Piwik::translate('General_AbandonedCarts') . ' - ' . Piwik::translate('Goals_VisitsUntilConv');
     $this->dimension = new VisitsUntilConversion();
     $this->constantRowsCount = true;
     $this->processedMetrics = false;
     $this->metrics = array('nb_conversions');
     $this->order = 20;
     $this->parameters = array('idGoal' => Piwik::LABEL_ID_GOAL_IS_ECOMMERCE_CART);
 }
Example #5
0
 protected function init()
 {
     parent::init();
     $this->processedMetrics = array(new AveragePrice(), new AverageQuantity(), new ProductConversionRate());
     $this->metrics = array('revenue', 'quantity', 'orders', 'nb_visits');
 }