Formio Versions - v22-appfactory/appfactory-wiki GitHub Wiki
The following are notes regarding some of the issues encountered when upgrading the formiojs library.
Approximately 13 attributes were added to the Select component. Due to the changes existing select component fields did not load correctly causing the Resources to not load and breaking the mapping to the database table/column. The solution was to edit each component (all types) and reselect the Resources and API setting for the table/column. No determination was made for what caused the load failure.
2. The choice select library changed the name of the function to select an option from existing data
Choices is a select control library used by the formio select component. The function to set the select option changed from setValueByChoice to setChoiceByValue which caused an error. Changing to the new name resolved the issue and the function continued to work as before.
This one is particulary strange since existing form select components continued to have option data in the old format while any new select component fields added to a form contained option data in a new format.
- Old Format
{
value: {
label: 'label string',
value: integer/string/object
}
}- New Format
{
label: '<span>label string</span>',
value: integer/string/object
}The solution was to create a getNormalizedObject function which will return either format into a common object.