M
M
msimrial2015-09-16 09:14:01
Google
msimrial, 2015-09-16 09:14:01

Why is there a difference between real orders and google analytics ecommerce?

Set code

{if isset($products_ga) and $page_name == 'order-opc' OR $page_name == 'module-cashondelivery-validation' OR $page_name == 'order-confirmation'}
            ga('require', 'ecommerce');
            ga('ecommerce:addTransaction', {
                'id': '{$customer_ga.id}',                   // Transaction ID. Required.
                'affiliation': 'none',   // Affiliation or store name.
                'revenue': 'none',             // Grand Total.
                'shipping': 'none',               // Shipping.
                'tax': 'none',                   // Tax.
                'currencyCode': 'UAN'  // local currency code.
            });
            {foreach from=$products_ga item=item}
            ga('ecommerce:addItem', {
                'id': '{$item['id_product']}',                   // Transaction ID. Required.
                'name': '{$item['name']}',    // Product name. Required.
                'sku': '{$item['reference']}',               // SKU/code.
                'category': '{$item['category']}',       // Category or variation.
                'price': '{$item['id_product']}',                // Unit price.
                'quantity': '{$item['price_wt']}'                  // Quantity.
            });
            {/foreach}
            ga('ecommerce:send');
            ga('set', 'currencyCode', 'UAN');
            {/if}

to /head , the code works by dropping orders, but on the goals page, a different indicator does not reach 20 orders, what could be the problem, or should it be?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
A
Alex Safonov, 2015-09-16
@msimrial

All this economy is transferred to analytics through JS.
One js error on the page is not caught and nothing will go to the analytics.
The script did not load due to connection problems, the same thing.
Somewhere in Ajax they screwed up, the order went through, ga - no.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question