.. _finance:
Finance
=======
.. figure:: /_static/using/finance/finance.png
:alt: Finance
:width: 100%
Finance
With the finance module you can create quotations, orders and invoices. You can clearly keep track of the process
from the first customer contact till the completion of your project or sale.
Initial setup
-------------
There are a couple of modules related to finance. You should consider which ones you need:
- Finance: Base module for creating quotations, orders and invoices.
- Catalog: If you need a catalog of products that can be added to quotes and invoices.
- Contracts: Contracts create repeating invoices or orders.
- PayPal, Mollie & MultiSafePay: Payment providers for online payments.
Navigate to System settings -> modules and install the modules you need:
.. figure:: /_static/using/finance/modules.png
:alt: Install modules
:width: 100%
Install modules
Then reload Group-Office so the System settings page is updated with the new options.
Languages
`````````
The finance module is multilingual. It takes over the language from the address book. You'll have to configure various
templates for quotes, invoices, reminders, emails etc. They all have a language
option. Organisations and contacts also have a language option. The contact language will be used to find a
template in their language. If not found it will fall back on the first language.
The template syntax and examples :ref:`are found below in the templates section`.
.. _Business finance:
Business
````````
After reloading navigate to System settings -> Business and double click your business. Make sure your business
has a correct name and organization from the address book. Also make sure your address book entry has a valid,
address, bank details and contact details. These will appear on your templates for quotes, invoices etc.
.. figure:: /_static/using/finance/business.png
:alt: Business
:width: 100%
Business
Debtor management
~~~~~~~~~~~~~~~~~
In the debtor management tab you can modify the PDF template for the statement and debtor profile. The profile
controls when a customer should receive a reminder and how often. You can also setup to create a task to call the
customer about payments.
.. figure:: /_static/using/finance/debtor-management.png
:alt: Business
:width: 100%
Debtor management
Permissions
~~~~~~~~~~~
Make sure everyone in the organisation has read permission for the business.
Books
`````
Now that the business has been setup it's time to configure books for your business. By default it already has
a book installed for all of the supported types:
- Sales invoices
- Sales orders
- Purchase invoices
- Purchase orders
- Quotes
It might be that you don't need all of these types. You can remove the ones you don't need. Edit the properties
of the books you need. By clicking the 3 dots behind the book and choose "Edit".
.. figure:: /_static/using/finance/book-general.png
:alt: Book dialog
:width: 100%
Book dialog
Here you can edit:
- Name
- :ref:`Business`
- Type: See above.
- Number format: You can use %T that will be replaced by a prefix of the type, %Y for the year and a number of 00000 for the standard length of the generated number.
- Next number: the next document will get this number.
- Currency
- Business model: When B2B is selected the customer selection will select organisations, with B2C it will select contacts.
- Greeting and closing are defaults for the fields in new quotes. You can use template tags in these fields. TODO document tags.
Statuses
~~~~~~~~
By default some statuses are always present based on the state of the document:
- Invoices
- Draft: The invoice is new and doesn't have a number yet
- Sent: The invoice has been sent to the customer
- Late: The invoice was not paid in time
- Paid: The invoice as paid
- Quotes and Orders
- Draft: The quote is new and doesn't have a number yet
- Sent: The quote has been sent to the customer
- Late: The quote was not accepted in time (see business settings)
- Accepted: The quote was accepted
- Rejected: The quote was rejected
- Complete: The quote was invoiced in full
In the statuses tab of the book properties you can define your own statuses that suit your business process.
They will appear between late and complete.
PDF and E-mail templates
~~~~~~~~~~~~~~~~~~~~~~~~
Here you can customise what the PDF looks like you'll send to the customer. Remember to complete your address book
entry that is connected to your :ref:`business`.
Default templates
*****************
The default E-mail/PDF templates are used when you click on the "Email" or "PDF" button from the document's detail panel when
it's in the draft status:
.. figure:: /_static/using/finance/draft-quote.png
:alt: Draft quote
:width: 100%
Draft quote
In the e-mail templates you can also add some standard attachments like your general terms and conditions.
The templates are very flexible. Perhaps you just want to upload your logo or stationary paper, you can also
fully customize the display of the data using HTML and template tags.
A typical quote e-mail template might look like this:
.. figure:: /_static/using/finance/email-template.png
:alt: E-mail template
:width: 100%
E-mail template
Additional templates
********************
The additional E-mail/PDF templates become available after the quote or order has been accepted. You can add
extra documents and e-mails for your workflow like shipping manifests or work orders.
.. figure:: /_static/using/finance/additional-templates.png
:alt: Draft quote
:width: 100%
Draft quote
Using the finance module
------------------------
Now that you've got your business and books setup you can start using it. We'll explain it using a typical workflow.
Quote workflow
``````````````
It starts with creating a contact. Create a contact with an organisation and make sure to enter an address,
e-mail address so it will look nice on the quote. From the contact detail panel click the add(+) button and select
"Quote":
.. figure:: /_static/using/finance/create-quote-from-contact.png
:alt: Draft quote
:width: 100%
Draft quote
This will open the edit dialog for the quote. It will select the first available book that has the type quote set:
.. figure:: /_static/using/finance/edit-quote.png
:alt: Edit quote
:width: 100%
Edit quote
You can add a greeting on top of the items table and closing. Defaults for these fields can be configured in the `Books`_.
The items can be grouped or it can just be a flat list. How these items are presented to the customer can be
customized in the PDF templates. Maybe you don't want to show line prices or only want to show the group totals
and keep the items private. The templates are very flexible.
Save the document and it will close showing the detail panel:
.. figure:: /_static/using/finance/draft-quote.png
:alt: Draft quote
:width: 100%
Draft quote
Review PDF
``````````
Click the "PDF" button to review it. By default it looks like this:
.. figure:: /_static/using/finance/quote-pdf.png
:alt: Quote PDF
:width: 100%
Quote PDF
.. note:: If the template is not ready yet, you might want to leave this page open. You can make changes to the PDF template and reload this preview to see the changes immediately.
Send quote
``````````
If the PDF looks good then it's ready for sending. Click the "E-mail" button to send it. Make sure your e-mail account has
been setup.
The quote will now get a number. When you send the e-mail it's status will automatically change to "Sent".
.. figure:: /_static/using/finance/email-quote.png
:alt: E-mail quote
:width: 100%
E-mail quote
The sent e-mail will be attached to the quote. When the customer replies to your e-mail it will automatically be
linked to the quote too.
Accepted quote
``````````````
When the customer replies you can use the "Accept" or "Reject" button to update the status.
The toolbar will change:
.. figure:: /_static/using/finance/accepted-quote.png
:alt: Accepted quote
:width: 100%
Accepted quote
From here on you can use custom statuses and documents that suit your workflow. You may want to create a project
from here to track time, or sent a partial invoice using the invoice button.
When the quote is invoiced in full it will automatically update it's status to "Completed".
Invoice
```````
When you create an invoice from a quote the invoice progress is shown with a progress bar:
.. figure:: /_static/using/finance/invoice-progress.png
:alt: Invoice progress
:width: 100%
Invoice progress
You can also see the open and paid invoices in the panel.
You can of course also create manual invoices without creating a quote first. This works similar to creating
quotes.
Purchase orders & invoices
``````````````````````````
You can also generate purchase orders from quotes or orders. You need to setup products with a supplier
in the catalog first:
.. figure:: /_static/using/finance/catalog.png
:alt: Catalog
:width: 100%
Catalog
Now repeat the quote process above and add some catalog items with the supplier set. A panel with "Purchased items" and
a "Create purchase orders" button will appear.
.. figure:: /_static/using/finance/purchase-orders-from-quote.png
:alt: Purchase orders from a quote
:width: 100%
Purchase orders from a quote
When you click the button it will generate purchase orders for each supplier. You can send those and when
you receive them you can add the supplier purchase invoice and it will show as delivered in the quote or order.
Payments
````````
You can manually add payments to the invoices but you can also import them using a CSV or MT940 file. It's also
possible to connect a payment provider like PayPal, Mollie, MultiSafePay or any other that we can integrate for you.
Debtors
```````
Click "Debtors" to view debtors and their outstanding invoices. With the "Actionable" filter you can view only
those that need to be reminded. You can control that in the `Debtor management`_.
.. figure:: /_static/using/finance/debtors.png
:alt: Debtors
:width: 100%
Debtors
From the "Process actions" menu you can choose a real or test run. With the test run it will be sent to the account used
for sending out reminders configured in the :ref:`Business`.
The outstanding invoices statement looks like this by default:
.. figure:: /_static/using/finance/outstanding-invoices.png
:alt: Outstanding invoices
:width: 100%
Outstanding invoices
When there are debtors to be notified you are reminded with a badge in the menu:
.. figure:: /_static/using/finance/menu-badges.png
:alt: Menu badges
Menu badges
Reports
```````
You can view a yearly and monthly turnover report from the more menu in the main grid:
.. figure:: /_static/using/finance/monthly-report.png
:alt: Monthly report
:width: 100%
Monthly report
You can also export to excel or CSV
Contracts
---------
With contracts you can create recurring invoices or orders. When they are due for sending you're notified with a badge (see above).
You can filter to show only the contracts due for sending. Then via the menu choose "Create due invoices now" and they
will all be created and optionally sent out via e-mail.
.. figure:: /_static/using/finance/contracts.png
:alt: Contracts
:width: 100%
Contracts
Recurring payments
``````````````````
It's also possible for customers to give mandates for recurring payments via direct debit. The process for customers is
simple and user-friendly. They can now click the "Direct Debit" button instead of "Pay" and follow the same payment process to set
up their first recurring payment. Once the next invoice is generated in Group-Office, a background payment will be
automatically created using the mandate provided by the customer.
Our recurring payments feature is compatible with:
- SEPA Direct debit
- Credit Card
- Paypal
At the moment the only payment provider that implements this is `mollie.com `_.
Contact us if you desire to use another payment provider. We can implement this for you.
.. _finance_templates:
Templates
---------
You can setup :ref:`templates` For documents, emails and statements. The general template syntax is described
in :ref:`the document templates section here`.
Available variables
````````
You can use the following variables in these templates:
business
~~~~~~~~
The business the item belongs to.
- name
- contactId
- hourlyRevenue
book
~~~~
The book of a document.
- name
- businessId
- currency
document
~~~~~~~~
The invoice, quote, order, po.
- document.number
- document.date
- document.sentAt
- document.expiresAt
- document.acceptedAt
- document.createdBy
- document.createdAt
- document.modifiedBy
- document.modifiedAt
- document.customerTo
- document.customerStreet
- document.customerZipCode
- document.customerCity
- document.customerState
- document.customerCountryCode
- document.vatReverseCharge
- document.greeting
- document.closing
- document.showTotals
- document.showPricePerLine
- document.itemGroups[]
document.itemGroup
++++++++++++++++++
- title
- showTotals
- items[]
itemGroup.item
++++++++++++++
- quantity
- description
- unitPrice
- unitCost
- vatRate
- discount
- articleId
customer
~~~~~~~~
The organization or contact of the customer
- customer.salutation
- customer.name
- customer.prefix
- customer.firstName
- customer.middleName
- customer.lastName
- customer.suffix
- customer.jobTitle
- customer.gender
- customer.organizations: Array(same properties as contact)
- customer.dates: Array (type, date)
- customer.emailAddresses: Array(type, email)
- customer.phoneNumbers: Array(type, number)
- customer.addresses: Array(type, street, street2, zipCode, city, state, country, countryCode)
- customer.urls: Array(type, url)
- customer.debtorNumber
- customer.IBAN
- customer.vatNo
- customer.registrationNumber
- :ref:`custom-fields`, :ref:`See the templates section for the syntax`
contact
~~~~~~~
The contact set for the document if it's book's business model is set to B2B.
Same fields as customer above but prefixed with "contact".
creator
~~~~~~~
The user who created the document.
- creator.displayName
- creator.username
- creator.profile (Contact from address book)
Examples
````````
Example quote
~~~~~~~~~~~~~
.. code-block:: html
|
{{template.name}}
|
[if {{logo}}]
[/if]
|
|
To:
{{document.customerTo}}
{{document.formattedAddress|nl2br}}
[if {{customer.vatNo}}]
VAT no.: {{customer.vatNo}}
[/if]
| Number: | {{document.number}} |
| Date: | {{document.date|date:d-m-Y}} |
[if {{document.reference}}]
| Reference: | {{document.reference}} |
[/if]
|
Offered by:
[assign businessOrg = business.contactId | entity:Contact]
{{businessOrg.name}}
[assign bAddress = businessOrg.addresses | filter:type:"postal" | first]
[if !{{bAddress}}]
[assign bAddress = businessOrg.addresses | first]
[/if]
{{bAddress.formatted|nl2br}}
[assign orgEmail = businessOrg.emailAddresses | sort:type:"work" | first | prop:email]
[if {{orgEmail}}]
| e-mail: | {{orgEmail}} |
[/if]
[assign orgNumber = businessOrg.phoneNumbers | sort:type:"work" | first | prop:number]
[if {{orgNumber}}]
| tel: | {{orgNumber}} |
[/if]
|
| Bank: | {{businessOrg.nameBank}} |
| IBAN: | {{businessOrg.IBAN}} |
| BIC: | {{businessOrg.BIC}} |
|
| VAT no.: | {{businessOrg.vatNo}} |
| Company no.: | {{businessOrg.registrationNumber}} |
|
[if {{document.greeting}}]
{{document.greeting}}
[/if]
[if {{document.showPricePerLine}}]
| Quantity |
Description |
[else]
Description |
[/if]
[if {{document.showPricePerLine}}]Price[/if] |
[each itemGroup in document.itemGroups]
[if {{itemGroup.showAs}} != "hidden"]
[if {{itemGroup.showAs}} == "single"]
[if {{document.showPricePerLine}}]
| 1 |
{{itemGroup.title}} |
{{book.currency}} {{itemGroup.subTotalPrice|number}} |
[else]
{{itemGroup.title}} |
[/if]
[else]
[if {{itemGroup.title}}]
| {{itemGroup.title}} |
[/if]
[each item in itemGroup.items]
[if {{item.description}} == "__PAGEBREAK__"]
[else]
[if {{document.showPricePerLine}}]
| {{item.quantity|number}} |
{{item.description|nl2br}} |
[assign rowTotal = {{item.unitPrice}} * {{item.quantity}} ]
{{book.currency}} {{rowTotal|number}} |
[else]
{{item.description|nl2br}} |
[/if]
[/if]
[/each]
[if {{itemGroup.showAs}} == "groupwithtotal"]
|
[if {{document.showPricePerLine}}]Total[else]Price[/if]:
|
{{book.currency}} {{itemGroup.subTotalPrice|number}}
|
[/if]
[/if]
[/if]
[/each]
[if {{document.showTotals}}]
[if {{document.vatTotals|count}} > 0]
[if {{document.showPricePerLine}}]
|
|
|
[/if]
|
Subtotal:
|
{{book.currency}} {{document.subTotalPrice|number}}
|
[/if]
[if {{document.vatReverseCharge}}]
|
VAT Reverse charge (0%):
|
{{book.currency}} 0.00
|
[else]
[each vatTotal in document.vatTotals]
|
VAT {{vatTotal.rate|number}}%:
|
{{book.currency}} {{vatTotal.price|number}}
|
[/each]
[/if]
|
|
|
|
Total:
|
{{book.currency}} {{document.totalPrice|number}}
|
[/if]
[if {{document.closing}}]
{{document.closing}}
[/if]
Terms
This document is valid for one month after the date above. Please contact us if you have any questions.
To accept this offer please sign here and return:
Signed by:
Date:
Example statement
~~~~~~~~~~~~~~~~~
.. code-block:: html
|
{{template.name}}
{{date|date:d-m-Y}}
|
[if {{logo}}]
[/if]
|
|
To:
{{customer.name}}
[assign address = customer.addresses | filter:type:"postal" | first]
[if !{{address}}]
[assign address = customer.addresses | first]
[/if]
{{address.formatted|nl2br}}
|
From:
[assign businessOrg = business.contactId | entity:Contact]
{{businessOrg.name}}
[assign bAddress = businessOrg.addresses | filter:type:"postal" | first]
[if !{{bAddress}}]
[assign bAddress = businessOrg.addresses | first]
[/if]
{{bAddress.formatted|nl2br}}
[assign orgEmail = businessOrg.emailAddresses | sort:type:"work" | first | prop:email]
[if {{orgEmail}}]
| E-mail: | {{orgEmail}} |
[/if]
[assign orgNumber = businessOrg.phoneNumbers | sort:type:"work" | first | prop:number]
[if {{orgNumber}}]
| Phone: | {{orgNumber}} |
[/if]
|
[if {{businessOrg.nameBank}}]
| Bank: | {{businessOrg.nameBank}} |
[/if]
| IBAN: | {{businessOrg.IBAN}} |
[if {{businessOrg.BIC}}]
| BIC: | {{businessOrg.BIC}} |
[/if]
|
[if {{businessOrg.vatNo}}]
| VAT no.: | {{businessOrg.vatNo}} |
[/if]
[if {{businessOrg.registrationNumber}}]
| Reg no.: | {{businessOrg.registrationNumber}} |
[/if]
|
| Invoice no. |
Date |
Due |
Amount |
Paid |
To be paid |
[assign total = 0]
[each invoice in invoices]
| {{invoice.number}} |
{{invoice.date|date:d-m-Y}} |
{{invoice.expiresAt|date:d-m-Y}} |
{{book.currency}} {{invoice.totalPrice|number}} |
{{book.currency}} {{invoice.paidAmount|number}} |
[assign balance = {{invoice.totalPrice}} - {{invoice.paidAmount}} ]
[assign parent.total = {{parent.total}} + {{balance}}]
{{book.currency}} {{balance|number}} |
[/each]
|
Total to be paid:
|
{{book.currency}} {{total|number}}
|
Please pay the outstanding amount immediately. If you're having trouble paying please contact us.
Payment Providers
-----------------
We have integrated some payment providers. If you need another one feel free to contact us!
PayPal
``````
Go to the PayPal developer portal and setup credentials. You can setup sandbox credentials for testing and live credentials:
https://developer.paypal.com/dashboard/applications
Make sure the PayPal module is installed and fill in the PayPal credentials at System Settings -> Paypal:
.. figure:: /_static/system-settings/paypal/system-settings.png
:width: 100%
PayPal system settings
When this is setup the "Pay with paypal" button will appear on the invoice page:
.. figure:: /_static/system-settings/paypal/invoice.png
:width: 100%
Invoice page
Mollie
``````
The setup for https://mollie.com is very similar to PayPal:
- Login to your Mollie account
- Go to Developers -> API keys
- Copy the key
Now in Group-Office install the Mollie module and enter the key in System Settings -> Mollie
MultiSafePay
````````````
The setup for https://www.multisafepay.com is very similar to PayPal:
- Login to your MultiSafePay account
- Go to Developers -> API keys
- Copy the key
Now in Group-Office install the MultiSafePay module and enter the key in System Settings -> MultiSafePay