You are here

public static function CommerceGoogleTagManagerActionAddToCart::getInfo in Commerce Google Tag Manager 7.2

Defines the action.

Return value

array

File

includes/rules/CommerceGoogleTagManagerActionAddToCart.php, line 14
This file contains the "Send Add To Cart event to GTM" action definition.

Class

CommerceGoogleTagManagerActionAddToCart
@file This file contains the "Send Add To Cart event to GTM" action definition.

Code

public static function getInfo() {
  return self::getDefaultsInfo() + array(
    'label' => t('Send "Add to Cart" event to google analytics via GTM'),
    'parameter' => array(
      'item' => array(
        'type' => 'commerce_line_item',
        'label' => t('Line Item in the Order'),
      ),
      'count' => array(
        'type' => 'text',
        'label' => t('The count of items added to the Cart'),
        'optional' => TRUE,
      ),
    ),
  );
}