formio.js icon indicating copy to clipboard operation
formio.js copied to clipboard

"Allow Manual Override of Calculated Value" prevents calculation altogether

Open BradBouquio opened this issue 2 years ago • 2 comments

Steps to recreate: Create a number component with default settings. Create a radio component with two options, Yes and No with the values 1 and 0. In the calculated value section of the radio component, enter a test calculation eg: value = data.number > 5 ? 1 : 0; This calculation works, however when you check the box "Allow Manual Override of Calculated Value" in the radio component, you would expect the calculation to still happen and also be able to override it if you want to. Instead, the calculation doesn't happen at all.

BradBouquio avatar Jul 11 '23 14:07 BradBouquio

For some reason the Radio believes it has been manually modified and rejects the calculation. Does this affect other components or just Radio?

travist avatar Aug 03 '23 13:08 travist

Other components as well. Tested on select, number, and checkbox and the same issue occurs.

BradBouquio avatar Aug 03 '23 13:08 BradBouquio

@BradBouquio I couldn't replicate the issue you mentioned in [email protected]. Please let us know if you still face the same issue.

https://github.com/formio/formio.js/assets/128126697/900f401c-ed7a-4329-b878-9a0e09a5b8e5

5264.json

olgabann avatar Apr 03 '24 12:04 olgabann

Yes the issue has been resolved 👍

BradBouquio avatar Apr 03 '24 13:04 BradBouquio