Custom Templates for DeepL backed up and EmailMonkey. GS University was also re-downloaded. Then small scripts updated like for Chubb.

This commit is contained in:
Norm Rasmussen
2025-02-25 17:01:36 -05:00
parent 74d46e88f4
commit a62a76f5d1
288 changed files with 9886 additions and 152 deletions

View File

@ -1,3 +1,46 @@
{% if current_person.signed_in? %}
{% assign splitted_email = current_person.email | split: "@" %}
{% assign splitted_domain = splitted_email[1] | split: "." %}
{% assign account_name = splitted_domain[0] %}
<script>
document.addEventListener('DOMContentLoaded', () => {
const cookieName = 'GSUTimestamp';
const cookieValue = document.cookie.split('; ').find(row => row.startsWith(cookieName + '='));
const currentTimestamp = Date.now();
if (!cookieValue) {
document.cookie = `${cookieName}=${currentTimestamp}; path=/`;
identifyLearner();
return;
}
const cookieTimestamp = parseInt(cookieValue.split('=')[1], 10);
const thirtyMinutesInMillis = 30 * 60 * 1000;
if (currentTimestamp > cookieTimestamp + thirtyMinutesInMillis) {
document.cookie = `${cookieName}=${currentTimestamp}; path=/`;
identifyLearner();
}
});
function identifyLearner() {
aptrinsic('identify',
{
'id': "{{ current_person.id }}",
'email': "{{ current_person.email }}",
'signedUpAt': new Date("{{ current_person.created_at }}").getTime(),
'firstName': "{{ current_person.first_name }}",
'lastName': "{{ current_person.last_name }}"
},
{
'id': "{{ account_name }}",
'name': "{{ account_name }}"
}
);
}
</script>
{% endif %}
<header class="np-header np-header-color">
<div class="np-header-top np-hidden-mobile">
<ul class="np-header-top-nav">