In my angular app, I have a bootstrap multiple select. When i do not give an ng-model attribute, it works as expected.
<select name="sample" class="form-control" multiple>
<option
ng-repeat="item in vm.items"
value="{{item.id}}"
selected>
{{item.name}}
</option>
</select>
This selects all the available options.
But I provide an ng-model, only the last value gets selected.
<select name="sample" class="form-control" multiple ng-model="someModel">
<option
ng-repeat="item in vm.items"
value="{{item.id}}"
selected>
{{item.name}}
</option>
</select>
Am I missing something here?