Order object {{ order }} contains information about the order, with filter print_r the content is listed.
Order withdrawals
For consumer sales within EU there is a 14-days return policy which also dictates an withdrawal process, as simple as placing the order.
The order object contains a withdrawable state.
{% if order.withdrawable %}
<div class="ml-auto"><button class="btn btn-xs btn-secondary" @click="withdrawOrder('{{order.customerEmail}}','{{order.reference}}')">Withdraw order</button></div>
{% endif %}
withdrawal form
{% form 'order_withdrawal' %}
The form needs to collect customer information (email, customerId or username) and order information (reference, orderId or number) for being able to process the request server side.
withdrawal.liquid template
/order/withdrawal.liquid template is used as the confirmation page for order withdrawals.