Developer forum

Forum » Ecommerce - Standard features » Order.Paymethod.RecurringSupport

Order.Paymethod.RecurringSupport

Pernille Mortensen
Reply

Hello,

I am creating an ecom shop and would like to create recurring orders. I have read https://doc.dynamicweb.com/documentation-9/ecommerce/carts-orders/recurring-orders but it seems like I have missed a basic but important step.

In the shopping cart app I use the standard templates InformationRecurringOrders.html and ReceiptRecurringOrders.html an they have a check:
If Defined(Ecom:Order.PaymentMethod.RecurringSupport)

This check returns false and the option to create a recurring order is not visible. I have tried using invoice payment with no checkout handler and Card payment using Quickpay checkout handler, but no succes. 

Is there an option I need to activate to use recurring orders - on the product, on the payment method or on the shop? Or is there anything else I need to do for it to work and make the RecurringSupport check return true?


Replies

 
Nicolai Pedersen Dynamicweb Employee
Nicolai Pedersen
Reply

Hi Pernille

Both invoice payment (uses what is called "DefaultCheckoutHandler" and Quickpay supports recurring. So as long as the cart is not marked as quote, it should work. 

There is a difference between creating a recurring order template and creating an order based on a recurring template.

To create a recurring order template, you just need to set 5 values to create it. 

  • EcomRecurringOrderCreate (true|false)
  • EcomOrderRecurringInterval (i.e. 1-30)
  • EcomOrderRecurringIntervalUnit (Days|Weeks|Months)
  • EcomOrderRecurringStartDate (Valid date)
  • EcomOrderRecurringEndDate (Valid date)

Payment is of course part of recurring - so the payment gateway either has to be the default checkouthandler (sending an invoice usually) or a payment gateway that supports saved credit cards and recurring - both things needs to be setup in order to get a payment each time an order is placed based o a recurring order template. That check is the one setting the Ecom:Order.PaymentMethod.RecurringSupport value.

Before that check will return true, you have to ensure that the payment method id is set on the order (by submitting the EcomCartPaymethodId field with a payment method that supports recurring) or by setting one of the payments as default for the country you have set as default (Yeah I know...!!!)

BR Nicolai

 
Pernille Mortensen
Reply

Thank you for your answer, Nicolai. Unfortunately I am not able to make it work yet.

I am using invoice payment (DefaultCheckoutHandler) and the cart is not marked as quote.

I am using the default InformationRecurringOrders.html template and it includes the five fields you mention. I have tried removing the "RecurringSupport"-check and tried converting to razor but still no luck. It seems like the five fields / values do not even exist and they are not in the TemplateTags - neither is RecurringSupport.

I have set invoice payment as the default payment for my default country and even tried implementing two identical information steps - just to make sure that the payment method id is set.

I wonder if it is better to create a support ticket for this?

 

 
Pernille Mortensen
Reply

Just an update on this:

The issue was me not being logged in as a user when doing this. Only registered users can create a recurring order - not regular website visitors.

 
Nicolai Pedersen Dynamicweb Employee
Nicolai Pedersen
Reply

Ah - that explains.

Thank you for getting back with that.

 

You must be logged in to post in the forum