angular-google-analytics icon indicating copy to clipboard operation
angular-google-analytics copied to clipboard

Change currency after initialization

Open KrisBraun opened this issue 7 years ago • 3 comments

Sometimes currency is a user-selectable option at checkout. I couldn't find a method to change the currency after configuring AnalyticsProvider. Could a method be exposed?

KrisBraun avatar Dec 16 '16 05:12 KrisBraun

@KrisBraun Do you know how this value is communicated if changed after configuration? Can you use the set method?

justinsa avatar Dec 16 '16 20:12 justinsa

I'm calling this, and I think it might be working:

    Analytics.set('&cu', this.currency)

It's just that I can see the saved currency is passed in the ecommerce:addTransaction call, which I assumed would override any previous set value.

KrisBraun avatar Dec 21 '16 03:12 KrisBraun

is there a setting for changing a custom metric to a currency?

tcrite avatar Mar 16 '18 22:03 tcrite