From 51b9530a0499d5fe7ecf023c0c48473a1d82b1e7 Mon Sep 17 00:00:00 2001 From: Michael Hall Date: Thu, 1 Feb 2018 23:03:12 -0500 Subject: [PATCH] Add ability for pages to override google analytics page path --- get_together/templates/get_together/base.html | 1 + get_together/templates/get_together/events/create_event.html | 4 ++++ get_together/templates/get_together/events/show_event.html | 2 +- get_together/templates/get_together/teams/show_team.html | 2 +- 4 files changed, 7 insertions(+), 2 deletions(-) diff --git a/get_together/templates/get_together/base.html b/get_together/templates/get_together/base.html index dc2fec3..aa03b60 100644 --- a/get_together/templates/get_together/base.html +++ b/get_together/templates/get_together/base.html @@ -17,6 +17,7 @@ gtag('js', new Date()); gtag('config', '{{settings.GOOGLE_ANALYTICS_ID}}'); + {% block extra_google_analytics %}{% endblock %} {% endif %} diff --git a/get_together/templates/get_together/events/create_event.html b/get_together/templates/get_together/events/create_event.html index eaf1d6c..7c63813 100644 --- a/get_together/templates/get_together/events/create_event.html +++ b/get_together/templates/get_together/events/create_event.html @@ -1,5 +1,9 @@ {% extends "get_together/base.html" %} +{% block extra_google_analytics %} + gtag('config', '{{settings.GOOGLE_ANALYTICS_ID}}', {'page_path': '/team/+create-event/'}); +{% endblock %} + {% block content %}

Plan a Get Together

diff --git a/get_together/templates/get_together/events/show_event.html b/get_together/templates/get_together/events/show_event.html index a9f23e0..ddbe1b6 100644 --- a/get_together/templates/get_together/events/show_event.html +++ b/get_together/templates/get_together/events/show_event.html @@ -41,7 +41,7 @@
-
{{attendee.user}} {{ attendee.status_name }}
+
{{attendee.user}} {{ attendee.status_name }}
{% if attendee.role > 0 %}{{ attendee.role_name }}{% endif %}
diff --git a/get_together/templates/get_together/teams/show_team.html b/get_together/templates/get_together/teams/show_team.html index fbbc1f8..01a9efe 100644 --- a/get_together/templates/get_together/teams/show_team.html +++ b/get_together/templates/get_together/teams/show_team.html @@ -46,7 +46,7 @@
-
{{member.user}}
+
{{member.user}}
{% if member.role > 0 %}{{ member.role_name }}{% endif %}