NASA-IMPACT / nasa-apt-frontend

Web application for NASA-APT
Apache License 2.0
4 stars 2 forks source link

Move the template format to the event name (Google Analytics) #568

Closed vgeorge closed 11 months ago

vgeorge commented 11 months ago

Contributes to https://github.com/NASA-IMPACT/nasa-apt/issues/807.

In https://github.com/NASA-IMPACT/nasa-apt-frontend/pull/563 we added custom events for tracking template downloads by format, but it seems the event parameter template_format is not persisted after some time in the GA dashboard.

In this PR I moved the format to the event name, which should allow tracking download events by format older than 30 mins.

How to test:

The other reports won't show the events right away because GA doesn't aggregate events for the current day. They should appear after they are older that 1 day.

@wrynearson this is ready for review.

vgeorge commented 11 months ago

@wrynearson are you referring to the Google Docs template? I tested it now, and the three format types are appearing in the Analytics console:

apt-stats

wrynearson commented 11 months ago

Yes, I was referring to the Google Doc template. Let's push this.

wrynearson commented 11 months ago

@vgeorge was this updated with the Production GA code? cc @sunu

vgeorge commented 11 months ago

@wrynearson the events were appearing in the production panel, we don't need to update the code. The issue was with event parameters, which aren't persisted for more than 30 mins. We should be able to see the updated event names in production.