This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
use Drupal\commerce_google_tag_manager\Event\AlterEventDataEvent; | |
class AlterShippingData implements EventSubscriberInterface { | |
public static function getSubscribedEvents() { | |
return [ | |
'commerce_gtm_enhanced_ecommerce.alter_event_data' => 'addShipping' | |
]; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
use Drupal\commerce_google_tag_manager\Event\TrackCheckoutStepEvent; | |
<?php | |
class CheckoutOptionSubscriber implements EventSubscriberInterface { | |
public static function getSubscribedEvents() { | |
return [ | |
'commerce_google_tag_manager.track_checkout_step' => 'trackUser' | |
]; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
use Drupal\commerce_google_tag_manager\Event\AlterProductEvent; | |
class AlterProductSubscriber implements EventSubscriberInterface { | |
public static function getSubscribedEvents() { | |
return [ | |
'commerce_gtm_enhanced_ecommerce.alter_product' => 'alterProduct' | |
]; |