You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: Readme.md
+11-4Lines changed: 11 additions & 4 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -4,17 +4,24 @@
4
4
5
5
Gain clear insights into important metrics about your customers, using Google Analytics.
6
6
7
-
## Notes
7
+
To use it, you will need to create a Google Analytics account and insert your Google Analytics Identifier into the Module configuration page.
8
8
9
-
Enhanced Ecommerce must be enabled in Google Analytics settings for full functionality. Otherwise, some data (refunds etc.) will not be visible. Follow [instructions][4].
9
+
### Notes
10
10
11
-
Google Tag Assistant will report "No HTTP Response detected" error in Prestashop back-office. **This is not a bug.** This happens, because the module does not send page views in BO, not to influence statistics. Only events, like refunds, are sent from BO.
11
+
Enhanced Ecommerce must be enabled in Google Analytics settings for full functionality. Otherwise, some data (refunds etc.) will not be visible. Follow [the related instructions][4].
12
+
13
+
### Configure
14
+
15
+
1. Install the module into your shop.
16
+
2. Create an account on Google Analytics if you do not have one.
17
+
3. Go on the "Configure" page of the module to insert your Google Analytics Identifier.
18
+
4. The data will then be sent to Google Analytics and you can monitor/explore it.
12
19
13
20
## Contributing
14
21
15
22
PrestaShop modules are open-source extensions to the PrestaShop e-commerce solution. Everyone is welcome and even encouraged to contribute with their own improvements.
16
23
17
-
Google Analytics is compatible with all versions of PrestaShop 1.7 and 1.6
24
+
Google Analytics is compatible with all versions of PrestaShop 1.7 and 1.6.
Copy file name to clipboardExpand all lines: classes/Form/ConfigurationForm.php
+55-6Lines changed: 55 additions & 6 deletions
Original file line number
Diff line number
Diff line change
@@ -22,7 +22,9 @@
22
22
23
23
useAdminController;
24
24
useConfiguration;
25
+
useContext;
25
26
useHelperForm;
27
+
useOrderState;
26
28
usePs_Googleanalytics;
27
29
useShop;
28
30
useTools;
@@ -101,12 +103,12 @@ public function generate()
101
103
[
102
104
'id' => 'ga_userid_enabled',
103
105
'value' => 1,
104
-
'label' => $this->module->l('Enabled'),
106
+
'label' => $this->module->l('Yes'),
105
107
],
106
108
[
107
109
'id' => 'ga_userid_disabled',
108
110
'value' => 0,
109
-
'label' => $this->module->l('Disabled'),
111
+
'label' => $this->module->l('No'),
110
112
], ],
111
113
],
112
114
[
@@ -118,15 +120,46 @@ public function generate()
118
120
[
119
121
'id' => 'ga_anonymize_enabled',
120
122
'value' => 1,
121
-
'label' => $this->module->l('Enabled'),
123
+
'label' => $this->module->l('Yes'),
122
124
],
123
125
[
124
126
'id' => 'ga_anonymize_disabled',
125
127
'value' => 0,
126
-
'label' => $this->module->l('Disabled'),
128
+
'label' => $this->module->l('No'),
127
129
],
128
130
],
129
131
],
132
+
[
133
+
'type' => 'switch',
134
+
'label' => $this->module->l('Enable Back Office Tracking'),
135
+
'name' => 'GA_TRACK_BACKOFFICE_ENABLED',
136
+
'hint' => $this->module->l('Use this option to enable the tracking inside the Back Office'),
137
+
'values' => [
138
+
[
139
+
'id' => 'ga_track_backoffice',
140
+
'value' => 1,
141
+
'label' => $this->module->l('Yes'),
142
+
],
143
+
[
144
+
'id' => 'ga_do_not_track_backoffice',
145
+
'value' => 0,
146
+
'label' => $this->module->l('No'),
147
+
],
148
+
],
149
+
],
150
+
[
151
+
'type' => 'select',
152
+
'label' => $this->module->l('Cancelled order states'),
153
+
'name' => 'GA_CANCELLED_STATES',
154
+
'desc' => $this->module->l('Choose order states, in which you consider the given order cancelled. This will be usually only the default "Cancelled" state, but some shops may have extra states like "Returned" etc.'),
0 commit comments