Author: Yuri Gee
Date: 1 May 2025
2 minute read time
In this short discussion, I will present two methods for assigning static values to currency fields in BPM workflows while maintaining the record's original currency type.
Scenario 1
In some business scenarios, you might need to set a currency field to a predefined value, such as 0.00 for a cancelled or deferred opportunity. However, using the standard assignment option in BPM with Constants – Currency requires a specific currency type. For instance, if you choose USD, it will compel the opportunity to convert from its original currency (which could be EUR, AUD, or another currency).
To address this, you can utilize an additional Currency field with a predefined value to assign to your target Currency field. Alternatively, for setting a value of 0.00, you can leverage any existing Currency field in the record's original currency type by using a subtraction expression such as: Likely – Likely. This approach will effectively yield 0.00.
Scenario 2
Imagine a situation where you need to assign static values to multiple currency fields in SugarBPM without having to create a separate field for each value. In such situation, you can create a single additional field named "Current Currency," which reflects the record's original currency. This field can be configured with the calculated formula:
related($currencies, "name")
Afterward, you can design a Process Business Rule and add it into the BPM process definition created in scenario 1. The Business Rule will resolve the Current Currency and assign the desired static values to the necessary fields matching the Current currency. This can be achieved using the Business Rule's Constants – Currency value selector, as shown in the following image.
Additional notes
By applying the BPM process outlined above (tested in SugarCRM 25.1), the Test Currency and Test Currency 2 fields will be populated with arbitrary static values and 0.00, all while preserving the record's original currency. This ensures that all currency fields on the record remain consistent and that calculations are accurate.
I hope these scenarios and proposed solutions will be valuable in improving your day-to-day experience with SugarCRM. I encourage you to share your thoughts and feedback on this discussion!