How to add a business rule for expenses

Tip: If you are looking for how to add a business rule for invoices, read this article.
Tip: If you are curious about the most commonly used business rules for expenses, read this article.

A business rule is a rule that allows you to perform certain actions automatically under certain conditions, such as changing the status of an expense, sending notifications and starting an authorization flow.

In this article, we'll cover a business rule that triggers an authorization flow.

Tip: Read this article if you want to know more about how you can use a business rule to automatically change the status, for example to make certain values ​​mandatory or to automatically approve certain expenses.

Note: adding a business rule is only possible for a user with admin rights.

Make sure you are logged into the Klippa Web App as a user with "admin" rights.

In the left menu, navigate to Settings and then Company. You are now in the company account settings.

Then click on Company Settings / Business Rules and on the green button Add at the top right.



As an example, we have already added a number of business rules in our overview (see above). Hereby a brief explanation of how our business rules are implemented. The rule with the lowest order (1) is executed first. Below you can see what each business rule does in order.

1) Check whether mandatory fields are completed, otherwise status is incomplete.
2) Lunch costs under 5 euros are automatically approved.
3) For expenses from one of the team leaders, our financial director approves.
4) For all other expenses, trigger an authorization flow based on the chosen cost center.

The most common business rules for invoices are the following:

Trigger authorization flow based on cost center chosen by a user (example in this article).
Trigger authorization flow based on a user's group.

Tip: if you are curious about more possibilities of business rules for expenses, read this article about the most common rules or this article about using other conditions and automatically changing a status through a business rule.
Below is an example of a business rule that determines which authorization flow is triggered when the cost center "Operations" is chosen by an expense submitter.



In the following steps we will show you successively how to set the 5. general information at the top, the 6. conditions and associated parameters and 7. the action and the target of the business rule.

Enter the general information at the top of the business line:

Description: clearly indicate the purpose of the business rule. In our example the approval of the cost center operations, so we choose "Approval Operations" as the description. If you use both the expense and invoice module at Klippa, we recommend that you also describe the document type, then it becomes "Expenses: Approval Operations".

Active: Choose active if you want the business rule to be applied to invoices that are submitted.

Order: This determines the order in which the business rules are executed. The lower the number, the earlier the rule is executed. In our example we choose "4" because we want the business rules with order 1,2,3 to be executed before this business rule is executed.

Document Type: Determine to which document type the business rule applies. In our case expenses.

Fill in the conditions and parameters:

With a condition you determine how the rule is applied, for example by comparing a certain value. With parameters we determine when the business rule is applied, in other words: under what conditions do we apply the rule? It is also possible not to specify any conditions. Then the rule applies to all expenses. However, at the target (see tip at the bottom of this article) you can still determine on which (groups of) users the rule is executed.



Conditions & parameters: in our example we choose "Compare field value", because we want that the business rule is applied to all expenses with "cost center" - "equal to" - "903 - Operations". In this article we explain how to make cost centers visible to submitters.

Tip: use the plus sign to add multiple conditions, then choose AND if you want the business rule to be applied to expenses that meet all conditions. Choose OR if you want the business rule to be applied to expenses that meet at least one of the conditions.
Tip: it is possible to select comparison parameters other than "equal to", for example "one of" if you want the rule to apply to multiple values.
Below is an example where the above tips (2 conditions and use comparison parameter "one of") are applied:


Enter the Action and the Aim:

The action determines what happens to an expense if the condition(s) are met. The target concerns who the rule applies to, in other words: to which user (group) the business rule is applied.



Action: in our example we choose "Set up authorization flow", because we want the authorization flow "Approval Tessa Rover" to be triggered for the expenses where the user has chosen the cost center "operations".

Note: you can only choose authorization flows of the chosen document type (in our example "expenses") or document type "Everything".
Tip: In this article it is explained how to create an authorization flow.

Target: In our example we chose "All users and groups" because we want this rule to be applied regardless of who is submitting the expense.

Tip: If you do not use cost centers or another parameter to determine which authorization flow should be triggered, you can also select a group of users under "target" to which the business rule applies. In this article we explain how to add users to groups.

Finally, click on Create to add the business rule.
Was this article helpful?
Cancel
Thank you!