From 51f458b63bdbcac070c4107fb7d25c45d318c8f4 Mon Sep 17 00:00:00 2001 From: Hillel Coren Date: Tue, 28 Nov 2017 10:44:28 +0200 Subject: [PATCH] Update GA item name --- app/Listeners/AnalyticsListener.php | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/app/Listeners/AnalyticsListener.php b/app/Listeners/AnalyticsListener.php index 9b8ba4b15e..aae2695120 100644 --- a/app/Listeners/AnalyticsListener.php +++ b/app/Listeners/AnalyticsListener.php @@ -40,6 +40,10 @@ class AnalyticsListener $item = $invoice->invoice_items->last()->product_key; $currencyCode = $client->getCurrencyCode(); + if ($account->isNinjaAccount() && \App::runningInConsole()) { + $item .= ' [R]'; + } + $base = "v=1&tid={$analyticsId}&cid={$client->public_id}&cu={$currencyCode}&ti={$invoice->invoice_number}"; $url = $base . "&t=transaction&ta=ninja&tr={$amount}";