Dynamically Add Options To A Angular Chosen Combo Box April 20, 2023 Post a Comment The following code doesn't work: ng-model='trainer_list' multiple class="form-control" data-placeholder="Select Multiple Trainers"> <option value="{{trainer.id}}" ng-repeat="trainer in trainers"> {{trainer.name}} </option> </select> Copy Debug your variable trainers Just add this code anywhere in your page to debug, <label> To Do: Remove this after testing. Trainer = {{trainers}} </label> Copy And see what are the values in trainer. Is this variable is updating after your server call? Solution 2: This is how I resolved it: In your select tag, put ng-if="trainers". This would prevent DOM loading until your http request is completed Share Post a Comment for "Dynamically Add Options To A Angular Chosen Combo Box"
Post a Comment for "Dynamically Add Options To A Angular Chosen Combo Box"