Skip to content

Add Google Tag Manager to usage tab in User Settings

Lauren Barker requested to merge add-gtm-usage-tab-user-settings into master

What does this MR do and why?

We've got instructions to add Google Tag Manager to the checkout flow. The usage tab in User Settings view are currently missing the necessary tags to provide coverage.

I've also added OneTrust to each view to allow users to appropriately manage their cookie settings across these pages.

Screenshots or screen recordings

These are strongly recommended to assist reviewers and reduce the time to merge your change.

  1. Google Tag Manger https://tagmanager.google.com/#/home Screen_Shot_2022-01-14_at_9.54.46_AM
  2. Open the Tag Assistant and follow instructions there on enabling debugging support on your localhost. Screen_Shot_2022-01-14_at_10.01.33_AM
  3. Verify GTM is working Screen_Shot_2022-01-14_at_10.01.47_AM Screen_Shot_2022-01-14_at_10.01.55_AM

How to set up and validate locally

Similar to the steps in !58494 (merged),

  1. Go to Google Tag Manager (https://tagmanager.google.com/) and create new container. Grab your ID there.
  2. Edit your config/gitlab.yml and add under extra: values for google_tag_manager_nonce_id and google_tag_manager_id that should be your GTM id from previous step.
  3. Restart GDK
  4. Enable the feature flag with Feature.enable(:gtm_nonce) via Rails console.
  5. Sign out from your local GDK instance.
  6. Open the Tag Assistant and follow instructions there on enabling debugging support on your localhost.
  7. Verify GTM is working /-/profile/usage_quotas#pipelines-quota-tab pages.

MR acceptance checklist

This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.

Edited by Lauren Barker

Merge request reports