-
Notifications
You must be signed in to change notification settings - Fork 0
/
template.tpl
167 lines (142 loc) · 10.4 KB
/
template.tpl
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
___TERMS_OF_SERVICE___
By creating or modifying this file you agree to Google Tag Manager's Community
Template Gallery Developer Terms of Service available at
https://developers.google.com/tag-manager/gallery-tos (or such other URL as
Google may provide), as modified from time to time.
___INFO___
{
"type": "TAG",
"id": "cvt_temp_public_id",
"version": 1,
"securityGroups": [],
"displayName": "Contentsquare - ETR Event",
"brand": {
"id": "github.com_contentsquare-ps",
"displayName": "contentsquare-ps",
"thumbnail": "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAANEAAADRCAIAAADdWMC4AAAACXBIWXMAABcRAAAXEQHKJvM/AAAULklEQVR4nO2dTWhb2X7AjyL5OvK9StKEYjmL14Itby0UePCIiUsLtcCmlMYQP5gSL+xFGC/iQGa8SDwzniw8M5Bk4UcWzsJph44HPLRQGxwe9D0NmkUXEcpWVhavhSelJZkk9/pDspTbxXkVwnas83XP+Z9772+VgD7u0fn5f77PP+K6LgoJkcgp1Q8QEjhC50JkEzoXIpvQuRDZhM6FyCam+gE0w3bc7fIBySst69TgQPjzHkP4oxxPoVi3HbdUPqhU31eqTdt5v/2iwfZRlhkZHOhCCGXSXQnr1OBArC8Z7UtGhT6vTkTC+Tn0/9HrWbFeKjdK5Ub1ZVPCl2aGjL5kdHAglkkb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3orSl4zqPt4URehciGwk3e0aEtIidC5ENqFzIbIJnQuRTehciGz+D6nvCNP4uCM/AAAAAElFTkSuQmCC"
},
"description": "Trigger an ETR (Event Triggered Recording) Event to Contentsquare",
"containerContexts": [
"WEB"
]
}
___TEMPLATE_PARAMETERS___
[
{
"type": "TEXT",
"name": "etrEventName",
"displayName": "ETR Event Name (Max 255 chars)",
"simpleValueType": true,
"valueValidators": [
{
"type": "NON_EMPTY"
}
],
"help": "Enter the name of the event you want to send which will trigger an ETR event that will save the recorded session of the visitor."
},
{
"type": "SELECT",
"name": "etrEventType",
"displayName": "ETR Event Type",
"macrosInSelect": false,
"selectItems": [
{
"value": "page",
"displayValue": "Page Level"
},
{
"value": "session",
"displayValue": "Session Level"
}
],
"simpleValueType": true,
"valueValidators": [],
"defaultValue": "session"
}
]
___SANDBOXED_JS_FOR_WEB_TEMPLATE___
//const logToConsole = require("logToConsole");
const createQueue = require("createQueue");
let _uxaPush = createQueue("_uxa");
var etrEventName = data.etrEventName;
var etrEventType = data.etrEventType;
let eventTypePrefix = "";
if (typeof etrEventName != "undefined") {
if (etrEventType === "page") {
eventTypePrefix = "@ETP@";
} else if (etrEventType === "session") {
eventTypePrefix = "@ETS@";
}
if (eventTypePrefix) {
_uxaPush(["trackEventTriggerRecording", eventTypePrefix + etrEventName]);
}
}
data.gtmOnSuccess();
___WEB_PERMISSIONS___
[
{
"instance": {
"key": {
"publicId": "access_globals",
"versionId": "1"
},
"param": [
{
"key": "keys",
"value": {
"type": 2,
"listItem": [
{
"type": 3,
"mapKey": [
{
"type": 1,
"string": "key"
},
{
"type": 1,
"string": "read"
},
{
"type": 1,
"string": "write"
},
{
"type": 1,
"string": "execute"
}
],
"mapValue": [
{
"type": 1,
"string": "_uxa"
},
{
"type": 8,
"boolean": true
},
{
"type": 8,
"boolean": true
},
{
"type": 8,
"boolean": true
}
]
}
]
}
}
]
},
"clientAnnotations": {
"isEditedByUser": true
},
"isRequired": true
}
]
___TESTS___
scenarios: []
___NOTES___
Developed by Uri Gobey @ Contentsquare