Developer forum

Forum » Ecommerce - Standard features » Abandoned cart recipients in 8.9.2.20

Abandoned cart recipients in 8.9.2.20

Martin Bakken Rickmann
Reply

Hi,

 

We have an abandoned cart setup on a version 8.9.2.20. Checkout can be done as guest and registered user. The client would like all customers - guests and users alike - to receive the abandoned cart email. But the abandoned cart email is only sent to recipients that register as users. 

 

We tested a bit of different settings and the recipient provider is current set like in the attachment. 

 

Any idea why the guest customers are not getting the abandoned cart email?

 

BR/

Martin

2018-10-30_09_10_38-Start.png

Replies

 
Nicolai Pedersen
Reply

Hi Martin

They will only receive an email if they have reached a step where the email address have been saved. So if I go to checkout, and fill out the order form, go to next step, i.e. payment, the order has the email attached to it and will show up in abandoned carts. If the anonymous user never enters the email address, it is kind of difficult to send them an email :-).

Also be aware that it is probably illegal (against the GDPR legislation) to use abandoned cart emails in the EU to anonymous users without an explicit consent - a checkbox where they actively accept that you send them the email. Make a search for it - or check out i.e. this article: https://www.willows-consulting.com/has-gdpr-killed-abandoned-cart-marketing/

BR Nicolai

 
Martin Bakken Rickmann
Reply

Hi Nicolai

We want to send the abandoned cart email to guest customers that have gone to payment gateway but not yet completed payment - meaning we have their email, permission and accept of terms. 

I do not see these guest customers in the table AccessUser table until after checkout is completed. I attached an image of my settings for the user part of cart module.  Any pointers?

BR/ 

Martin

 

 

 

 

2018-10-30_11_39_56-Clipboard.png 2018-10-30_11_47_58-Start.png
 
Nicolai Pedersen
Reply

HI Martin

I would need to see the settings of the abondoned cart provider in email marketing as well.

This is the raw SQL that finds the emails - and it adds some extra filtering based on the settings on your abondoned cart provider.

            Dim sql As New Text.StringBuilder()
            sql.AppendLine("SELECT  OrderID, OrderCustomerEmail, OrderCustomerName, OrderCustomerAccessUserID")
            sql.AppendLine("FROM EcomOrders")
            sql.AppendLine("WHERE")
            sql.AppendLine("      OrderComplete = 0")
            sql.AppendLine("  AND OrderCart = 1")
            sql.AppendLine("  AND OrderModified " & GetOrderModifiedWhereClause(IgnoreAbandonedCartsOlderThan, MarkAbandonedAfter))
            sql.AppendLine("  AND OrderCustomerEmail IS NOT NULL")
            sql.AppendLine("  AND OrderCustomerEmail <> ''")
            If RequireEitherCustomerLoggedInOrAcceptedTerms OrElse RequireCustomerLoggedIn OrElse RequireCustomerAcceptedSalesTerms Then
                sql.AppendLine("  AND (")
                If RequireEitherCustomerLoggedInOrAcceptedTerms OrElse RequireCustomerLoggedIn Then
                    sql.AppendLine("    OrderCustomerAccessUserID > 0")
                End If
                If RequireEitherCustomerLoggedInOrAcceptedTerms Then
                    sql.AppendLine("    OR")
                ElseIf RequireCustomerLoggedIn AndAlso RequireCustomerAcceptedSalesTerms Then
                    sql.AppendLine("    AND")
                End If
                If RequireEitherCustomerLoggedInOrAcceptedTerms OrElse RequireCustomerAcceptedSalesTerms Then
                    sql.AppendLine("    OrderCustomerAccepted = 1")
                End If
                sql.AppendLine("  )")
            End If
            If Not String.IsNullOrWhiteSpace(AbandonedCartsShop) Then
                sql.AppendLine("  AND OrderShopID = '" & AbandonedCartsShop & "'")
            End If
            If Not String.IsNullOrWhiteSpace(AbandonedCartsLanguage) Then
                sql.AppendLine("  AND OrderLanguageID = '" & AbandonedCartsLanguage & "'")
            End If

Looking at this, and seeing the code, I think it is because that when you start the checkout step, OrderCart in the database is no longer true - but false since the user is basically in a checkout step and has been converted to an order which is still not marked as complete.

So there are 2 options - somehow post back the order form when the email is entered without going to the checkout step - that will save the email on the order. The other option is to modify the standard provider you got here, and create you own version (it is just an addon) and remove that check from the SQL (and make other needed changes). I've attached the latest version of the provider used on DW8.

That said, I am not sure (actually pretty sure) that accepted terms is enough for sending out abandoned cart emails if you read the GDPR regulations. So still consider if this is for a brand that can take the heat if it comes up. From the regulation:

“... freely given, specific, informed and unambiguous indication ... by a statement or by a clear affirmative action ...”

I would say that you need something like this to be compliant.

[  ] Accept terms and condition
[  ] Accept emails from us with XX and YY

Eventhough I am not a legal advisor, this is what seems to be consensus from those wanting to stick to legislation without bending the rules.

BR Nicolai

 
Martin Bakken Rickmann
Reply

Hi Nicolai,

 

EDIT - I didn't read your response closely enough - sorry :-)

I totally agree on your points in regards with GDPR ;-) 

Thx for your response.  I see now where things go wrong/ could be optimized. When the user goes to payment step the OrderCart is set to 0. In your AbandonedCartRecipientProvider it should always be OrderCart=1. This means that only EcomOrders that are CARTs are included and not non-completed ORDERs. I have no full overview of what OrderCart does, but wouldn't it be better if the ORDER type items get included as well? These would be our primary audience for these emails.

What do you think?

BR

Maritn

 
Nicolai Pedersen
Reply

You could change it - but you would potentially sned abandoned cart emails to users that in the process of a checkout. Of course the time limit will handle most of them. It could also be a setting.

But it is your customer - so do whatever is needed.

Personally i would advice them not to do it for anonymous users.

 

You must be logged in to post in the forum