I have a nested json to select multiple services for appointment creation. I have implemented mat selection list. The selection list stores the values of only one group, if any values from second group is selected earlier values are removed. Could not understand where it is wrong?
Below is the plunker : https://stackblitz.com/edit/material-selection-list-5-0-0-pod6hb
I expect the output to be [1,2,3,4] in selected values when all options are selected.
At present its only [1,2] or [3,4]
Thanks in advance.
servicesList
and the[formControl] ="service"
is in that loop. So you're just overriding the same reference. – alphapilgrim