mirror of
https://github.com/edcommonwealth/sqm-dashboards.git
synced 2026-03-11 00:10:35 -07:00
Revert "Tie legacy analytics ID to environment"
This reverts commit 3e15194eff.
This will allow monitoring the new experience analytics to not be tampered by the
legacy analytics.
This commit is contained in:
parent
65ee27742a
commit
6aa9f00adc
2 changed files with 2 additions and 9 deletions
|
|
@ -1,7 +1,6 @@
|
|||
module Legacy
|
||||
class ApplicationController < ActionController::Base
|
||||
protect_from_forgery with: :exception, prepend: true
|
||||
before_action :set_google_analytics_id
|
||||
|
||||
layout "legacy/application"
|
||||
|
||||
|
|
@ -19,11 +18,5 @@ module Legacy
|
|||
end
|
||||
end
|
||||
|
||||
private
|
||||
|
||||
def set_google_analytics_id
|
||||
@google_analytics_id = ENV['GOOGLE_ANALYTICS_ID']
|
||||
end
|
||||
|
||||
end
|
||||
end
|
||||
|
|
|
|||
|
|
@ -13,13 +13,13 @@
|
|||
= javascript_include_tag 'application', 'data-turbolinks-track': 'reload'
|
||||
|
||||
/ Global site tag (gtag.js) - Google Analytics
|
||||
%script{:async => "", :src => "https://www.googletagmanager.com/gtag/js?id=#{@google_analytics_id}"}
|
||||
%script{:async => "", :src => "https://www.googletagmanager.com/gtag/js?id=UA-132936999-1"}
|
||||
:javascript
|
||||
window.dataLayer = window.dataLayer || [];
|
||||
function gtag(){dataLayer.push(arguments);}
|
||||
gtag('js', new Date());
|
||||
|
||||
gtag('config', #{@google_analytics_id.to_json.html_safe});
|
||||
gtag('config', 'UA-132936999-1');
|
||||
|
||||
%body
|
||||
.container
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue