Skip to content

Invoices

The Invoices feature is available in Sales Pack extension.

An Invoice is a billing document issued to a customer that details the products or services provided, including their quantities, prices, applicable taxes, and the total amount due.

You can add the Invoices panel to the Account detail view to be able to see related sales orders. Administration > Layout Manager > Accounts > Bottom Panels.

You can add the Invoices panel to Opportunity detail view at Administration > Layout Manager > Opportunities > Bottom Panels.

In the article:

Converting from Opportunity, Quote or Sales Order

Method 1. Create a new Invoice, on the form, specify the needed opportunity/quote/sales order. Data will be copied from the opportunity/quote/sales order to the created invoice.

Method 2. Create a new Invoice from Invoices relationship panel on the detail view of the opportunity/quote/sales order.

Total values layout

The layout of total value fields (in the bottom on detail view) can be modified at Administration > Layout Manager > Invoices > Bottom Total.

Invoice items

An Invoice has the list of items. Each item can represent a certain product or a service with the description, quantity, tax rate, list price, and unit price fields. It's possible to sort items manually.

There is the ability to add custom fields for Invoice Item entity type using the Entity Manager.

Invoice Items Layout

The layout of Invoice Items can be modified at Administration > Layout Manager > Invoice Items > List (Item).

Discount Rate

It's possible to specify a discount in percents. To have this ability, an administrator should add the Discount (%) field to the List (Item) layout.

Allocations

Inbound payments, credit notes, and write-offs can be allocated to an invoice. Allocations reduce the amount due of an invoice.

Applied allocations can be viewed in the Allocations panel of an invoice. To view details of a specific allocation, click View from the dropdown.

Payment terms

As of Sales Pack v4.0.

Payment term profiles can be managed at Administration > Payment Terms Profiles. The default payment term profile can be set at Administration > Sales Pack Settings. This profile will be pre-filled upon invoice creation.

A payment term profile defines items that correspond to payment installments. Each item defines a portion in percents and the number of days. Portions of all items must add up to 100. The number of days is used to calculate the Date Due of the installment by adding the value to the Date Invoiced.

Examples

  • Net 30. Use one item with 100% portion and 30 days.
  • CIA 25 / Net 20. 25% immediately and the rest after 20 days. Use two items: 25% with 0 days and 75% with 25 days.

Payment installments of a created invoice are available in the Installments panel in the Invoice detail view. The status of each installment updates automatically when a payment is allocated to the invoice. It can be one of the following: Unsettled, Partially Settled, or Settled.

A payment term profile can be assigned for a specific Account. The assigned to an account profile will be used when an invoice is created for that account. Note that the Payment Term Profile field is not added to the Account detail view by default. You need to add it at Administration > Entity Manager > Account > Layouts > Detail.

Debit notes

As of Sales Pack v4.0.

An invoice can be issued as a debit note. In the system, a debit note is an invoice record with the Type field set to Debit Note.

A debit note can be created at: Invoices tab > top right menu > Create Debit Note.

By default, debit notes use separate numbering. To use the same numbering, check Do not use separate numbering for Debit Notes at Administration > Sales Pack Settings.

To configure the debit note number prefix or change the next number, go to Administration > Entity Manager > Invoice > Fields > Number for Debit Notes (auto-incremented).

In a PDF Template, use {{type}} placeholder to print the type of the invoice document: Invoice or Debit Note.

Rounding

As of Sales Pack v4.0.

A rounding can be applied to an invoice. The invoice rounding is mandatory in some countries.

The rounding is applied before the grand total. The rounding method is controlled by a Rounding Profile assigned to the invoice.

Rounding profiles can be managed at Administration > Rounding Profiles. A rounding profile defines a rounding factor.

Rounding factor examples:

  • 1 – round to a whole number
  • 0.5 – round to 50 cents
  • 0.01 – round to 1 cent

The default rounding profile can be set at Administration > Sales Pack Settings. This profile will be pre-filled upon invoice creation.

When a credit note is created for an invoice, it inherits the rounding profile from the invoice.

In some cases, when tax-inclusive pricing is used, the discrepancy between the expected amount and the sum of the computed net prices is recorded on the rounding amount line.

Printing to PDF

Invoices can be printed to PDF. This action is available in the dropdown next to Edit button on the Invoice detail view. Then, you will be prompted to select a template. More info about printing to PDF is available here.

Templates

See the documentation for quote templates.

Tax number

The Sales Pack adds the Tax Number field to the Account entity type. Use this field to store VAT numbers. Note that including the VAT number on the invoice is mandatory in many jurisdictions.

Sending in email

An Invoice PDF can be sent in an email as an attachment. Open an invoice record, click the dropdown next to Edit button and then click Email PDF.

The default email template can be set by the administrator: Administration > Sales Pack Settings > Email Templates.

To have the Invoice entity selected as the email's parent, the administrator should add the Invoice entity type to the parent type list. Administration > Entity Manager > Email > Fields > Parent > Entity List. As of v3.0.

Automatic numbering

By default, the Number field is auto-incremented. You can disable auto-increment at Administration > Entity Manager > Invoice > Fields > Number. It's also possible to make the number field read-only.

The prefix of the next number, the next number itself and the quantity of digits in the number can be configured at Administration > Entity Manager > Invoice > Fields > numberA.

By default, there is no Name field on the Detail layout. The Number is used as a name. You can add the Number field at Administration > Entity Manager > Invoice > Layouts > Detail.

By default, the Name field is synced with Number. To be able to specify arbitrary names, you need to disable the Sync with Number and Read-only parameters at Administration > Entity Manager > Invoice > Fields > Name.

Copying values from product to invoice item

Field values can be transferred from a product to an invoice item upon product selection. Field names you want to be copied should coincide in Product and Invoice Item entities.

You can select which fields you need to be copied at Administration > Entity Manager > Invoice Item > Fields > Product > Fields to Copy.

Automation with Workflows or BPM

The following service actions are available in the Workflows and BPM tools:

  • Add Invoice Items
  • Convert Currency
  • Send in Email

E-Invoicing

As of Sales Pack v2.4.

Invoices can be exported to EN 16931 electronic invoices in a UBL format. The following CIUS specifications are supported:

  • XRechnung
  • PEPPOL BIS Billing 3.0
  • CIUS-RO e-Factura
  • CIUS-IT
  • CIUS-AT-GOV
  • CIUS-AT-NAT
  • CIUS-ES-FACE
  • NLCIUS

To export an Invoice to a UBL file, click E-Invoice from the dropdown menu next to the Edit button on the Invoice detail view. The UBL file can be also attached along with a PDF when sending an Invoice in email.

Note

An E-Invoice can exported only if it is valid. It must include certain mandatory fields depending on the specification.

Settings

E-Invoicing settings are available at Administration > Sales Pack Settings > Electronic Invoicing. Here you can specify the system Default Format to prevent the need to select the format each time you are exporting an invoice.

Specify Seller Information fields that will be included in electronic invoices. Fields, such as Company Name, Company Address, Electronic Address, VAT Number, etc.

Account

The Sales Pack adds additional fields to the Account entity type. The following fields of the Account are included in the E-Invoice:

  • Tax Number – to store VAT number;
  • Electronic Address Scheme
  • Electronic Address Identifier

Add these fields to the Account's Detail layout under: Administration > Entity Manager > Account > Layouts > Detail.

Invoice

A standard you use may require the Buyer Reference, Purchase Order Reference. The corresponding fields exist in the Invoice entity type, an administrator can add them to the Detail layout.

Additional fields that are mapped to E-Invoice:

  • Buyer Reference
  • Purchase Order Reference
  • Note

If you have a requirement to add fields that are not present in Espo out-of-the-box, a developer can implement a custom e-invoice preparator to map custom fields to e-invoice.

Country codes

The EN 16931 standard requires countries to be represented as ISO 3166-1 alpha-2 codes. But in Espo, the Address field allows a country to be an arbitrary string. As of EspoCRM v8.3 it's possible to map country names to ISO 3166-1 alpha-2 codes. This mapping is used when E-Invoices are generated.

Note that it's possible to automatically populate country records with English names.

Example: If you run business from Germany, your customer is also in Germany and you use the word Germany when storing the country in Espo, you need to create the Germany Address Country record with the DE code.

EN 16931 tax mapping

Tax codes can be mapped to UNCL5305 category code. Additionally, a mapping entry can specify a tax class. If the tax class is specified, the mapping will be applied to a document items with a product associated with that tax class.

Access mapping at: Administration > EN 16931 Tax Mapping.

Locking

An Invoice can be locked if it's completed or canceled. When a record is locked, a specific fields become read-only. An administrator can configure the field list at: Administration > Entity Manager > Invoice > Edit.

If the settings parameter Forbid order unlocking is checked, once a record is locked, it can be unlocked only by an administrator.

See also