AngularJS ng-options not rendering values

vigrx4tnnaa

New Member
How can figured out how i can render the value of options list, \[code\]$scope.limits = [ {value: '5', text: 'Afficher 5 par page'}, {value: '10', text: 'Afficher 10 par page'}, {value: '15', text: 'Afficher 15 par page'}, {value: '20', text: 'Afficher 20 par page'} ];<select id="limitType" name="limit" ng-model="limit" ng-options="limit.value as limit.text for limit in limits"></select> enregistrement par page\[/code\]Expected result (expecting in value="http://stackoverflow.com/questions/14425686/limit.value":\[code\]<select ng-options="option.value as option.text for option in limits" ng-model="limit" id="limitType" class="ng-pristine ng-valid"> <option value="http://stackoverflow.com/questions/14425686/5" selected="selected">Afficher 5 par page</option> <option value="http://stackoverflow.com/questions/14425686/10">Afficher 10 par page</option> <option value="http://stackoverflow.com/questions/14425686/15">Afficher 15 par page</option> <option value="http://stackoverflow.com/questions/14425686/20">Afficher 20 par page</option></select>\[/code\]Result:\[code\]<select ng-options="option.value as option.text for option in limits" ng-model="limit" id="limitType" class="ng-pristine ng-valid"> <option value="http://stackoverflow.com/questions/14425686/0" selected="selected">Afficher 5 par page</option> <option value="http://stackoverflow.com/questions/14425686/1">Afficher 10 par page</option> <option value="http://stackoverflow.com/questions/14425686/2">Afficher 15 par page</option> <option value="http://stackoverflow.com/questions/14425686/3">Afficher 20 par page</option></select>\[/code\]
 
Back
Top