Implemented fix for #9660 prevents finding a value for simple array of options #9742
Labels
Type: Bug
Issue contains a bug related to a specific component. Something about the component is not working
Milestone
I'm submitting a ... (check one with "x")
https://stackblitz.com/edit/primeng-dropdown-demo-pte6kg?file=src%2Fapp%2Fapp.component.html
Current behavior
When binding an array of simple objects (string[], int[]), the internal value does not get set because of trying to get option.value which does not exist. This is caused by the recent change of looking if OptionLabel is defined and defaulting to option.value instead of option which is how it previously worked.
Expected behavior
Binding an array of simple elements should set the binding of ngModel or correctly update the value of the dropdown
What is the motivation / use case for changing the behavior?
Keep existing functionality for simple cases
Angular version:
11.0
PrimeNG version:
11.1.0-rc.1
Browser:
all
The text was updated successfully, but these errors were encountered: