Reputation: 141
I have done Google Analytics Enhanced eCommerce implementation using GTM(Google Tag Manager) for eCommerce Website. I have implemented the Checkout funnels and its capturing the Drop-off details properly for all the payment methods except one which is Affirm payment method.I need some help to resolve this problem.
For the Checkout funnels we have 4 steps: Shipping, Payment, Order review and Confirmation(Thank you page). We have payment methods such as Credit card, PayPal, Affirm(https://www.affirm.com/) etc.
I am able to capture the flow properly along with the drop-off information at each step except for Affirm(https://www.affirm.com/). In the case of Affirm, on-click of Order Review button, it takes the user to Affirm payment page and after the successful payment, he will be redirected to Thank you page.
Now, if I check in GA dashboard Product List Performance section, I see one row for the product which shows the values till Product Checkouts column with the Unique Purchases column being 0, and another row with "(not set)" product list name where it populates only the Unique Purchases column to 1 with all other columns showing 0 values. Not sure why its happening. In the case of other payment methods we just show a pop-up window to pay the amount, but for Affirm, the page gets redirected to a third party page and that is where the payment happens. Please help me resolve this problem. Thanks.
//Shipping
window.dataLayer = window.dataLayer || [];
dataLayer.push({
'event': 'stepShipping',
'ecommerce': {
'checkout': {
'actionField': {'step': 1},
'products': gtmProducts
}
}
});
//Payment
window.dataLayer = window.dataLayer || [];
dataLayer.push({
'event': 'stepPayment',
'ecommerce': {
'checkout': {
'actionField': {'step': 2}
}
}
});
//Order review
window.dataLayer = window.dataLayer || [];
dataLayer.push({
'event': 'stepOrderReview',
'ecommerce': {
'checkout': {
'actionField': {'step': 3}
}
}
});
//Transaction
window.dataLayer = window.dataLayer || [];
dataLayer.push({
'event': 'orderConfirmation',
'ecommerce': {
'purchase': {
'actionField': {
'id': document.getElementById("transactionId").value,
'affiliation': 'Web',
'revenue': document.getElementById("transactionTotal").value,
'tax': document.getElementById("transactionTax").value,
'shipping': document.getElementById("transactionShipping").value
},
'products': items
}
}
});
Upvotes: 0
Views: 864
Reputation: 907
Put the domain affirm.com in the "referral exclusion list" of your Google Analytics property. This happens because product list attribution on GA only happens on the same session. When the client returns to the thank-you-page a new session is created if the domain is not on the referral exclusion list.
@DalmTo is right. This question is not programming related. I would write this answer as a comment if I had the necessary reputation...
Upvotes: 2