Value casting on retrieval of defaults prevents empty field
On retrieval of defaults values are casted dependent on the configured input data type. The problem with the current implementation is that for integers and floats initially empty form fields are not possible, because null
is casted, too, resulting in 0
. In my case it depends on the current state if there's actually a default or not.
https://lab.civicrm.org/extensions/form-processor/-/blob/2.0.6/Civi/FormProcessor/Runner.php#L231 https://lab.civicrm.org/extensions/form-processor/-/blob/2.0.6/Civi/FormProcessor/Type/GenericType.php#L82