action.skip

Deposit Invoices

← About Invoices

Certain business use cases require merchants or suppliers to ask their customers for advance payments. To this end, JustOn allows for creating deposit invoices.

Understanding Deposit Invoices

Businesses issue deposit invoices before any goods or services are supplied, usually with the intention to secure a sale. The deposit (or down payment) is a partial amount or a percentage of the total amount, which is to be paid up front. After the sale is completed, the deposit invoice is closed and the final invoice is issued.

VAT on deposit invoices in Germany

In Germany, deposit invoices are subject to VAT, as regular invoices do. The tax due date, however, differs: For regular invoices, the tax immediately arises with the invoice issuance. With deposit invoices, the tax becomes chargeable only on receipt of the down payment (German VAT Act, Art. 13).

This may be favorable in certain business scenarios: You can issue a deposit invoice to secure your deal before delivering the goods or services, but you are not immediately liable to taxes.

Enabling Deposit Invoices
Managing Deposit or Pro Forma Invoices

Deposit Invoices in JustOn

JustOn Billing & Invoice Management supports deposit invoices when billing arbitrary objects.

Basically, the creation of a deposit invoice is controlled using the ON field ON_Type on the source object. If this field is set to Deposit, JustOn generates a deposit invoice.

In order to request an advance payment with your deposit invoice, use the ON fields ON_DepositRate or ON_DepositAmount. Depending on your use case, you can then specify either a percentage value of the invoice total or a fixed amount as the deposit.

Once deposit billing is set up accordingly, JustOn Billing & Invoice Management creates one invoice line item of the type Deposit that represents the deposit amount. If the actual invoice line items are subject to different tax rates, the software applies the highest tax rate to the deposit invoice line item.

The deposit invoice is subject to the usual invoice proceedings and business processes, including

However, as deposit invoices do usually not constitute a legally binding payment request, they are, by default, exempt from dunnings. If your business, however, requires issuing reminders for deposit invoices, you can still enable this feature.

If required by your accounting, you can, optionally, enable the bookkeeping data generation for deposit invoices. Note that finalizing the final invoice produces a reverse booking detail for originally booked deposit amount. In addition, JustOn allows for canceling deposit invoices that are not yet closed.

In case of errors, you may still need to void an issued deposit invoice. For details, see How to void a deposit invoice?

Note

When you use deposit invoicing, be aware that JustOn does not consider order discounts with the deposit invoices, but only when generating the final invoices.

Working With Deposit Invoices

The following sections describe how to work with deposit invoices, outlining their life cycle.

Deposit Invoice Creation

JustOn generates a deposit invoice if the field ON_Type on the source object is set to Deposit.

Note

Once you have set the field ON_Type on the source object to Deposit to trigger the deposit invoice creation, do not modify this field subsequently to make sure that the deposit invoicing features operate correctly.

You can define a deposit rate or a deposit amount using the fields ON_DepositRate or ON_DepositAmount on the source object.

Info

If both a deposit rate and a deposit amount is defined, the amount takes precedence.

Using a template detail named Deposit, you can provide appropriate texts for the invoice PDF, like the display type, deposit title or description (see PDF Contents).

After creating the deposit invoices, JustOn sets the custom field ON_ProformaInvoice on the source objects to the deposit invoices.

deposit_1
Creating a deposit invoice

Deposit Invoice Closure

Before you create the final invoice, you must close the deposit invoice. There are two ways to do so:

  • Using the Close button on an individual invoice
  • Using a custom flow to be triggered from a source record
Close button or custom process?

The procedure to close the invoices depends on your business use cases and the corresponding data structure in your org.

pro-forma_close_1

If you create invoices from a parent record in a parent-child relation, you most likely use a custom flow to be triggered from the relevant parent record. The process clears the custom fields ON_Invoice, ON_Type and ON_LastInvoiceRun on the parent source record, which allows for creating the final invoice from the same record.

pro-forma_close_2

If your invoice run involves multiple source records (for example, using multiple filters or via single source object configurations), the Close button on an individual invoice is the more appropriate approach. It clears the custom fields ON_Invoice, ON_Type and ON_LastInvoiceRun on all source records that are related to the current invoice to allow generating the final invoice. This saves the need for manually clearing these fields on the source records.

Using the Close button on an individual deposit invoice

  • sets the deposit invoice to the status Closed
  • unregisters any assigned payment balances
  • clears the custom fields ON_Invoice and ON_LastInvoiceRun on all related source records to allow generating the final invoice

If appropriate, you can use a custom flow to be triggered from a source record. Applying the specific Apex class that JustOn provides for this purpose, your flow

  • sets deposit invoices to the status Closed
  • clears the closed deposit invoices to 0
  • unregisters any assigned payment balances
  • sets the field RelatedInvoice of the now unregistered deposit payment balances to the corresponding deposit invoice
  • sets the custom field ON_Type to Final
  • clears the custom fields ON_Invoice and ON_LastInvoiceRun on the source record that triggers the process

deposit_2
Closing the deposit invoice via flow

Info

Be aware of the following specifics:

  • Unregistering deposit payment balances entails an invoice balance that does not equal zero, but the status Closed indicates that the paid deposit invoice does not represent an open receivable.
  • Usually, JustOn assigns unregistered deposit payment balances to the corresponding final invoices. Clearing the field RelatedInvoice of the unregistered deposit payment balance will allow to assign the balance to any matching invoice.

Note

After integrating with JustOn Cash Management to manage payment processes, users must cancel the entry produced for the deposit invoice to "release" any related payments. Using a payment assignment key makes sure that the involved payment will be associated with the entry produced for final invoice.

Final Invoice Creation

After you have closed the deposit invoice, you create the final invoice the same way and based on the same source records as the deposit invoice.

Doing so

  • registers the balances that were unregistered from the deposit invoice by the closing process to the final invoice
  • sets the field RelatedInvoice on the final invoice to the corresponding deposit invoice

deposit_3
Creating the final invoice, linked to the deposit invoice

Info

JustOn registers a down payment as a payment balance record. As invoices by default show related balance records, the final invoice shows the down payment information. Your business may, however, require to hide this information. In this case, you need a separate invoice template or a specific template detail that is configured to prevent the balance table from being printed. For details, see Hiding Balance Table.

Deposit Invoice and Final Invoice From Different Sources

Your business may require to create a deposit invoice from one source object and the related final invoice from another – using the generic invoice run in both cases. Think of the Salesforce CPQ process, for example: You can create the deposit invoice from a quote, and the final invoice from a CPQ subscription that is based on this quote.

In addition to the original deposit invoicing configuration, this approach involves

  • Setting the deposit invoice fields on the two source objects
  • Relating the deposit invoice with the second source object

For details, see Creating Deposit Invoice and Final Invoice From Different Sources.

Once set up, the solution may work as follows:

deposit_2_sources
Creating deposit invoice and final invoice from different sources

(1) JustOn generates a deposit invoice if the field ON_Type on the first source record is set to Deposit. Using the fields ON_DepositRate or ON_DepositAmount, you set the price of the deposit line item to be created. The field ON_ProformaInvoice on the source record points to the deposit invoice.

On payment registration, JustOn assigns the corresponding payment balance to the deposit invoice.

(2) When appropriate, you close the deposit invoice. In particular, this

  • unassigns the payment balance from the deposit invoice, and
  • creates the lookup between the second source record and the deposit invoice, that is, sets ON_ProformaInvoice on the second source record.

(3) With both ON_Type set to Final and ON_ProformaInvoice pointing to the deposit invoice on the second source record, JustOn generates the final invoice. It registers the payment balance, which has been previously unassigned from the deposit invoice, with the final invoice. Doing so reduces the final payment amount.

Deposit Invoice Structure

A deposit invoice consists of two parts:

  • The first part lists the invoice line items, which are represented as Information type invoice line items and therefore do not count for the grand total, followed by a subtotal section with tax breakdown.

    The display of the subtotal section is controlled using the checkbox Display Subtotal After on the last Information type invoice line item. Deselecting this checkbox removes the subtotal section from the invoice PDF.

  • The second part contains the invoice line item of the type Deposit, followed by the corresponding tax breakdown, grand total and payment amount.

    Remember that JustOn Billing & Invoice Management creates one deposit invoice line item to represent the deposit amount. If the actual invoice line items are subject to different tax rates, the software applies the highest tax rate to the deposit invoice line item.

The two parts are optional. Whether they are displayed or not depends on whether there are already actual invoice line items to show or, respectively, on whether there is an advance payment defined. At least one part must exist to print the invoice line item table.

Example invoice line item table of a deposit invoice:

Pos. Title Tax Rate Net Price
1 Some Goods 10% 1000
2 Some Service 20% 500
Subtotal Net 1500
Tax (10%) 100
Tax (20%) 200
Deposit Gross 1700
3 Down payment (50%) 20% 750
Tax (20%) 150
Grand Total 900
Payment Amount 900

Pos. 1 and 2 are Information invoice line items, which do not count for the grand total of the invoice. If you do not want the Information invoice line items to be displayed on the invoice PDF, you can hide them using this custom CSS:

tr.product.Information {
    display: none;
}

Pos. 3 is a Deposit invoice line item. The value depends on the deposit setting used: it is either calculated based on the net subtotal of all invoice line items and the defined deposit rate, or it can be included as an absolute net amount using the deposit value. In any case, JustOn Billing & Invoice Management applies the highest available tax rate to the deposit invoice line item.

The final invoice includes additional sections that show the received deposit payment and the remaining final payment, broken down into the net amount and the remaining tax amount.

This example shows a final invoice with one received deposit payment.

Pos. Title Tax Rate Net Price
1 Some Goods 10% 1000
2 Some Service 20% 500
Subtotal Net 1500
Tax (10%) 100
Tax (20%) 100
Grand Total 1700
Received Payments (net) -750
Tax on Received Payments -150
Received Payments (gross) -900
Remaining Final Payment (net) 750
Tax on Remaining Final Payment 50
Payment 06/10/2020 -900
Payment Amount 800

The following example shows a final invoice with two payments, where each payment has a different tax rate. To make it easier to understand, 20% and 25% are used as tax rates.

Pos. Title Tax Rate Net Price
1 Some Goods 10% 1000
2 Some Service 20% 500
Subtotal Net 1500
Tax (10%) 100
Tax (20%) 100
Grand Total 1700
Received Payments (net) -740
Tax on Received Payments -160
Tax on Received Payments (20 %) -100
Tax on Received Payments (25 %) -60
Received Payments (gross) -900
Remaining Final Payment (net) 760
Tax on Remaining Final Payment 40
Payment 06/10/2020 25 % -300
Payment 08/15/2020 20 % -600
Payment Amount 800

If there are multiple payments with different tax rates, the invoice includes the line Tax on Received Payments ([Tax Rate]) for each applied tax rate.

Deposit Invoice PDF Output Options

The lines Tax on Received Payments ([Tax Rate]) and Received Payments (gross) are hidden by the default CSS. You can use custom CSS to hide or show specific lines.

Look at these examples:

Show the Tax on Received Payments ([Tax Rate]) lines
.invoice-table .received-payments-tax-by-taxrate {
    display: table-row;
}
Show the Received Payments (gross) line
.invoice-table .received-payments-gross {
    display: table-row;
}
Hide the Received Payments (net) line
.invoice-table .received-payments-net {
    display: none;
}

You can override the labels according to your business requirements. For details, see Configuring Final Invoice Display.

There are two template fields that control the display of the corresponding balance information:

Template Field Description
Balance Columns Defines the columns for the balance table. The definition must be a list of balance field API names separated by semicolons. If BalanceTitle is used, the column will display the text defined in the field Balance Types.
The default definition is BalanceTitle;Date__c;Amount__c
Balance Types Specifies a mapping (in JSON notation) of the values defined in the Type field of the Balance object to some display text (which can include placeholders).
Types that are not specified in the mapping are not displayed on the invoice.

JustOn applies this configuration also to print the received payments on the final invoice PDF. To set these fields, you can use the Final template detail.

For the Final template detail, the default definition for Balance Columns is

BalanceTitle;Date__c;TaxRate__c;Amount__c

If required, you can also set the Balance Types to show only payments:

[ {
"type" : "Payment",
"title" : "Payment"
}, {
"type" : "Prepayment",
"title" : "Prepayment"
} ]

Info

The template detail Final is available as of JustOn 2.68. If you upgrade from a previous version, it may not be available. If required, you must create the template detail Final. For details, see Configuring Template Details.