How to automate downpayment process in your offers

Introduction

As many of you know we are able to accept the down payment for an event through our web portal. In this tutorial, we will show you how to integrate this in your offer so your customer can use the link in the offer to confirm his event.

Gather the required information

In order to set this up, we will need to have the following information and prepare your environment.

  1. Online payment facilitator ID.
  2. Online booking setup.
  3. Main email template for the offer.
  4. Project state ID when you want to send the link.

Configure the parameter

  1. Navigate to “Menu”->”Post Office”->”Template parameter”
  2. Create a new entry named “paymentlink”.
  3. The record type is “reservation”
  4. In the SQL field, you can paste the following statement.

    select coalesce((select first 1 ‘<p>To ensure your spot in this exciting activity we require a downpayment which can be done by following <a href=”https://booking.bmileisure.com/yourvenuename/downpayments/’ || BLP.F_BLP_ID || ‘”>this</a> link.</p>

    from T_BILL_PAYMENT BLP
    where BLP.F_BLP_STATE = and
    BLP.F_PM_ID = 24965 and
    exists(select null
    from T_BILL_2_BILL_PAYMENT B2B
    inner join T_BILL BL on BL.F_BL_ID = B2B.F_BL_ID
    where B2B.F_BLP_ID = BLP.F_BLP_ID and
    BL.F_PRJ_ID = @RECORDID)), ”) from rdb$database
  5. Adjust the bold text to some descriptive text of how you want the link to look like
  6. Adjust the red text to the right ID’s
  7. Save your work.

Implement the parameter

Now that we have our work in this parameter you can add this in any part of any “offer/proposal” template. We implemented the whole text, including the HTML tags in the parameter to make sure the client does not see anything related to the downpayment whenever there is no payment required.

image on how it looks in the system

How the Offer will show in case there is no payment required:

customerview

Practical usage notes

The setup is made so it takes the link of the first pending online payment. Meaning that if you want to ask for a second or any following payment the previous payment’s state has to change. This state can change by paying the requested amount or by manually changing it to another state.

Like this, you could also implement this link in the invoice and make a payment request for the outstanding amount.

To get information about how to create a payment request you can read this KB entry.