From: Jeff Davis Date: Mon, 28 Mar 2022 18:30:26 +0000 (-0700) Subject: LP#1966802: add Matomo support to Bootstrap OPAC X-Git-Url: https://old-git.evergreen-ils.org/?a=commitdiff_plain;h=7a57a199ecf4a0a6edd38414a00c7c9415d613c1;p=evergreen%2Ftadl.git LP#1966802: add Matomo support to Bootstrap OPAC Signed-off-by: Jeff Davis Signed-off-by: Jane Sandberg --- diff --git a/Open-ILS/src/templates-bootstrap/opac/parts/base.tt2 b/Open-ILS/src/templates-bootstrap/opac/parts/base.tt2 index eceb162f99..91030b7dc8 100755 --- a/Open-ILS/src/templates-bootstrap/opac/parts/base.tt2 +++ b/Open-ILS/src/templates-bootstrap/opac/parts/base.tt2 @@ -27,6 +27,12 @@ [% '' %] [% END %] + [% matomo_id = ctx.get_org_setting(ctx.search_ou, 'opac.analytics.matomo_id'); %] + [% matomo_url = ctx.get_org_setting(ctx.search_ou, 'opac.analytics.matomo_url'); %] + [% IF matomo_id && matomo_url %] + [% matomo_enabled = 1; %] + [% END %] + [%- libname = ctx.get_aou(ctx.search_ou).name; libname = libname | html; libsname = ctx.get_aou(ctx.search_ou).shortname; %] @@ -49,6 +55,7 @@ [% IF !ctx.is_staff %] [% INCLUDE 'opac/parts/goog_analytics.tt2' %] + [% INCLUDE 'opac/parts/matomo_analytics.tt2' %] [% END %] [% PROCESS 'opac/parts/stripe.tt2' %] diff --git a/Open-ILS/src/templates-bootstrap/opac/parts/matomo_analytics.tt2 b/Open-ILS/src/templates-bootstrap/opac/parts/matomo_analytics.tt2 new file mode 100644 index 0000000000..48c7c6769a --- /dev/null +++ b/Open-ILS/src/templates-bootstrap/opac/parts/matomo_analytics.tt2 @@ -0,0 +1,19 @@ +[%- PROCESS "opac/parts/header.tt2"; + IF matomo_enabled == 1 %] + + + + +[%- END %]