...
In order to comply with legal requirements this module introduces a google reviews e-mail consent on the success page. When placing an order, a user can see a modal that asks for consent for google reviews. There is also a google reviews logo displayed:
Table of Contents |
---|
Installation
Info |
---|
This module is optional. |
...
Admin settings can be found in Stores -> Configuration -> MageSuite -> Google Customer Review
...
General settings:
NameField | OptionOptions | Comment |
---|---|---|
Merchant ID |
Badge settings:
NameField | OptionOptions | Comment |
---|---|---|
Enabled | Yes/No | |
Position |
|
Opt-in setting:
NameField | Option | Comment |
---|---|---|
Enabled | Yes/No | |
Delivery time in days |
| |
GTIN Attribute |
...
Once verified, follow the integration instructions to add the code snippet below to the order confirmation page and adjust the variables as needed. Integrating the snippet is required for Google to show the opt-in for Google Customer Reviews in the shop.
...
.
...
Integration of google reviews logo
Indicate with the logo that the shop participates in the Google Customer Reviews program and includes the seller rating on your website.
First, paste the code snippet at the bottom of any page on your website and adjust the variables as needed. Then, check that the logo and associated text are displayed on your website as expected. Note: If there are no seller ratings, the message "No rating available" will be displayed.
...
Magesuite integration
In checkout_onepage_success.xml reviews-survey block is included:
Code Block |
---|
<referenceContainer name="before.body.end"> <block class="MageSuite\GoogleCustomerReviews\Block\Survey" name="magesuite.google_customer_reviews.survey" template="MageSuite_GoogleCustomerReviews::survey.phtml"> <arguments> var ratingBadgeContainer<argument name= document.createElement("div");"view_model" xsi:type="object">MageSuite\GoogleCustomerReviews\ViewModel\Survey</argument> </arguments> document.body.appendChild(ratingBadgeContainer);</block> </referenceContainer> |
The badge block is included on every page (default.xml):
Code Block |
---|
<referenceContainer name="before.body.end"> window.gapi.load('ratingbadge', function() {<block name="magesuite.google_customer_reviews.badge" template="MageSuite_GoogleCustomerReviews::badge.phtml"> <arguments> window.gapi.ratingbadge.render(ratingBadgeContainer, {"merchant_id": 113149439}); }); } </script><argument name="view_model" xsi:type="object">MageSuite\GoogleCustomerReviews\ViewModel\Badge</argument> </arguments> </block> </referenceContainer> |