Skip to content

Commit 80b511b

Browse files
authored
Update GoogleAnalyticActionLib.js
1 parent ef7cd10 commit 80b511b

1 file changed

Lines changed: 3 additions & 13 deletions

File tree

views/js/GoogleAnalyticActionLib.js

Lines changed: 3 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -76,22 +76,19 @@ var GoogleAnalyticEnhancedECommerce = {
7676
addToCart: function(Product) {
7777
this.add(Product);
7878
ga('ec:setAction', 'add');
79-
ga('send', 'event', 'UX', 'click', 'Add to Cart'); // Send data using an event.
79+
ga('send', 'event', 'UX', 'click', 'Add to Cart');
8080
},
8181

8282
removeFromCart: function(Product) {
8383
this.add(Product);
8484
ga('ec:setAction', 'remove');
85-
ga('send', 'event', 'UX', 'click', 'Remove From cart'); // Send data using an event.
85+
ga('send', 'event', 'UX', 'click', 'Remove From cart');
8686
},
8787

8888
addProductImpression: function(Product) {
89-
//ga('send', 'pageview');
9089
},
9190

92-
/**
93-
id, type, affiliation, revenue, tax, shipping and coupon.
94-
**/
91+
9592
refundByOrderId: function(Order) {
9693
/**
9794
* Refund an entire transaction.
@@ -103,11 +100,6 @@ var GoogleAnalyticEnhancedECommerce = {
103100
},
104101

105102
refundByProduct: function(Order) {
106-
/**
107-
* Refund a single product.
108-
**/
109-
//this.add(Product);
110-
111103
ga('ec:setAction', 'refund', {
112104
'id': Order.id, // Transaction ID is required for partial refund.
113105
});
@@ -148,8 +140,6 @@ var GoogleAnalyticEnhancedECommerce = {
148140
},
149141

150142
addTransaction: function(Order) {
151-
152-
//this.add(Product);
153143
ga('ec:setAction', 'purchase', Order);
154144
ga('send', 'event','Transaction','purchase', {
155145
'hitCallback': function() {

0 commit comments

Comments
 (0)