Skip to content
  • There are no suggestions because the search field is empty.

Add a calculated field to a contract template

A calculated field works out a total from the number and amount fields on a contract template, using a formula you build, so a total is never typed in by hand.

Where a contract holds several amounts — a base fee, a licence fee, add-on modules, support — the total is usually worked out by hand and goes stale the moment one of the figures changes. A calculated field keeps it right: it is a contract input field whose value is worked out from other fields on the same template. You build the formula yourself, so it can add, subtract, multiply and divide, for example to take off a discount, and the total updates itself on every contract.

Create the field

  1. Go to Settings > Contract input fields and select Create input field.
  2. Give it a name, for example "Total annual fee".
  3. Add a description. It appears as an i-icon next to the field, so use it to say what the total covers and what it leaves out.
  4. Set Input type to Calculated field and select Create.

Create input field dialogue with a name, a description and the input type set to Calculated field

Add it to a template

  1. Go to Settings > Contract templates and open the template.
  2. Go to the step the field belongs on and select Add field.
  3. Pick your new field under Custom fields in the dropdown.
  4. Build the formula from the number, amount and period fields already on the template. Select Add field or press Enter to open the field picker, then add an operator, and keep going until the formula is complete. You can use the mouse or the arrow keys. You can add (+), subtract (−), multiply (×) and divide (÷), and use parentheses to group parts of the formula, for example (Licence + Support fee + Extra add-ons) − Total discount.

 

calculatedfield

How it looks on a contract

On the contract the field shows the total, with the fields it is made up of listed underneath, so it is clear where the figure comes from. The field is locked, so nobody can type over the total by hand. It updates on its own whenever one of those amounts changes, so a price increase or decrease is reflected straight away.

Calculated field on a contract showing the total in DKK, with the fields it is made up of listed underneath

Include a discount

A discount is simply a number field that you use in the formula. Create a number field, for example "Total discount", add it to the template, and decide in the formula how it is applied:

  • As an amount: enter the discount in your currency and subtract it, for example (Licence + Support fee + Extra add-ons) − Total discount.
  • As a percentage: enter it as a decimal, for example 0.2 for 20%, and multiply, for example (Licence + Support fee) − (Licence + Support fee) × Total discount.

When the discount is filled in on the contract, the total is recalculated straight away.

calculatedprice contract

See the total across your contracts

A calculated field can also be shown as a column in the contract overview, which gives you the total value of every contract in one list.

  1. Go to Contracts and filter the overview, for example on contracts made from your service agreement template.
  2. Select Edit column view, add the calculated field as a column and apply the change.
  3. Save the overview as a new view, so you can come back to the same list later.

editcolumn-calculatedamount

contractoverview-calculatedamount

The column updates when the figures on a contract change, so the view always shows the current total for each contract.

Important notes

  • Calculated fields require the Templates and Custom Fields add-on.
  • Number, amount and period fields can be included, with or without decimals. Once the formula is valid, an example of the result is shown below it before you save. Only fields already on the template can be used, so add them first.
  • The value cannot be edited on the contract — it follows the formula.
  • Calculated fields work the same way on asset, legal entity and process templates.

Tip: the fields do not have to be filled in by hand. If you use integrations, you could, for example, import the amounts from your finance system, and the total follows. This is optional.


Related Articles