1

Hi I am new to angularjs. how to select a group that will select all element of that group in option selection list.I am using this piece of code. I am not able to select group name.

<select ng-model="data.Id" ng-options="data.Id as data.name group by  data.dataGroup for data in dataarray" multiple>
    <option value="" disabled selected>Select Data</option>
</select>
  • try using `data.name for data in dataarray track by data.id` – Nilesh Nov 24 '15 at 16:38
  • Possible duplicate of [Select all options from dropdown on button click using AngularJS](http://stackoverflow.com/questions/33075791/select-all-options-from-dropdown-on-button-click-using-angularjs) – notAChance Nov 24 '15 at 16:39
  • @Nilesh i tried but its not selecting by group name.please refer link . http://stackoverflow.com/questions/28148815/angularjs-ngoptions-make-group-by-group-selectable – user3771709 Nov 24 '15 at 16:47
  • @xeon48 i want to select all option using particular group.there may be more than one group refer my above comment link for more clarification. – user3771709 Nov 24 '15 at 16:52

0 Answers0