Description of problem: A simple static dropdownlist dialog element on a service dialog fails when data type is integer and the dialog is edited to multiselect. An omnious error page appears and after that, the only option is to delete the affected service dialog since CF becomes unable to edit the dialog properly and further error pages will appear. Version-Release number of selected component (if applicable): 5.10.8.0-1 How reproducible: always Steps to Reproduce: 1. Automation -> Automate -> Customization 2. On "All Dialogs" -> Button Configuration -> Add new dialog 3. Dialog name "test5" 4. Add a dropdownlist to the "new section" 5. Edit the dropdownlist 6. Leave the default 1,2,3 options 7. Change value type to INTEGER, set the default to "One" 8. Also set REQUIERED to Yes. 9. Save and then Save the dialog 10. Select dialog test5 and Configuration -> edit this dialog 11. Edit the dropdownlist 12. In Options, change MULTISELECT to Yes 13. Save and then Save the dialog 14. Puff... Actual results: On the browser: URL https://10.10.0.38/api/service_dialogs/1000000000019 Status 500 Internal Server Error Content-Type application/json; charset=utf-8 Data {"error":{"kind":"internal_server_error","message":"undefined method `collect' for 1:Integer","klass":"NoMethodError"}} Click close, then Cancel (abort dialog edition) Unexpected error encountered Error text: undefined method `collect' for 1:Integer [miq_ae_customization/explorer] Now the dialog test5 cannot be edited anymore from CF. The only choice is to delete de dialog. Expected results: No error Additional info: No dynamic dialog elements are required to reproduce this issue.
Created attachment 1608767 [details] Error when trying to save the dialog
Created attachment 1608768 [details] Error after cancelling previous error and also canceling the dialog edtion the dialog cannot be edited anymore. It can only be deleted.
Created attachment 1608769 [details] production.log
Created attachment 1608770 [details] automation.log
Created attachment 1608771 [details] evm.log (compressed due to size)
Additional Info: I reproduced this with cfme-5.9.9.3-1 (CF 4.6)
I reproduced this with cfme-5.11.0.18-1 (CF5 Beta)
https://github.com/ManageIQ/ui-components/pull/432
https://github.com/ManageIQ/ui-components/pull/437
New commit detected on ManageIQ/ui-components/master: https://github.com/ManageIQ/ui-components/commit/c9c47999e72faa21ea2cf1b59a78408a8d9f3be8 commit c9c47999e72faa21ea2cf1b59a78408a8d9f3be8 Author: Martin Hradil <mhradil> AuthorDate: Tue Jan 14 23:20:29 2020 +0000 Commit: Martin Hradil <mhradil> CommitDate: Tue Jan 14 23:20:29 2020 +0000 Dialog Editor - reset default_value when changing dropdown type, values, or between single and multiselect Fixes https://bugzilla.redhat.com/show_bug.cgi?id=1746211 (cherry picked from commit 30797a2612b55297026c348621f0a8a2ead3ade3) src/dialog-editor/components/modal-field-template/modalFieldTemplateComponent.ts | 32 +- 1 file changed, 30 insertions(+), 2 deletions(-)
New commit detected on ManageIQ/ui-components/ivanchuk: https://github.com/ManageIQ/ui-components/commit/541f3e4eb5f0bd99fd920b3f4bee22c2deffb184 commit 541f3e4eb5f0bd99fd920b3f4bee22c2deffb184 Author: Martin Hradil <mhradil> AuthorDate: Wed Apr 22 16:00:52 2020 +0000 Commit: Martin Hradil <mhradil> CommitDate: Wed Apr 22 16:00:52 2020 +0000 Merge pull request #437 from mzazrivec/bug-1746211 Dialog Editor - reset default_value when changing dropdown type, values, or between single and multiselect (cherry picked from commit 2a03d66e50dabb9e9d04185fdb2b7881c1816237) https://bugzilla.redhat.com/show_bug.cgi?id=1746211 .travis.yml | 2 +- src/dialog-editor/components/field/field.html | 1 - src/dialog-editor/components/field/fieldComponent.spec.ts | 24 - src/dialog-editor/components/field/fieldComponent.ts | 9 - src/dialog-editor/components/modal-field-template/modalFieldTemplateComponent.ts | 37 +- 5 files changed, 35 insertions(+), 38 deletions(-)
The PR is now backported to ivanchuk branch. Please release a new version of ui-components and bump the version in OpsUI/SUI.
PRs with ui-components version bump: https://github.com/ManageIQ/manageiq-ui-classic/pull/7055 https://github.com/ManageIQ/manageiq-ui-service/pull/1642
Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory, and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. https://access.redhat.com/errata/RHSA-2020:2480