About Formulas
Portfoleon supports formulas in automation rules to perform simple calculations.
Portfoleon formula engine supports the following capabilities:
- Simple arithmetic operations,
+,-,*,/, and(). - Custom fields as
fields.field_code, wherefield_codeis the code of the field in the field editor. - Work item built-in fields:
id: internal work item identifiercode: work item codepercent_complete: work item percent completestatus_id: current work item status identifierdt_report: the date when the status was last updated
- Special values:
@Meis the current user ID@MeResourceis the current user’s resource ID (if that resource is linked to the user)@Todayis the current date
- Functions written in a form
function_name(parameter1, parameter2, ..., parameterN)
Functions
If
if(condition, result_if_true, result_if_false)
if will return the result depending on the condition.
Days Between
days_between(date1, date2)
days_between will return distance in days between date1 and date2. The distance will be positive if date2 is later than date1, otherwise it will be negative.
Days Add
days_add(date1, days)
days_add will return a date that is date1 shifted by the amount of days days.