angularjs - How create select from object in Angular? -


how easy create select list object js?

object:

0: {userswork: "600", name: "salaria"}, 1: {userswork: "700", name: "bavaria"} 

i need create:

<select>    <option value="600">salaria</option>    <option value="700">bavaria</option> </select> 

i tried using ng-option:

<option ng-show="specializationselect == {{value.usersspecializationidspecialization}}" value="{{value.usersworkspaceiduser}}" ng-repeat="(key, value) in options">{{value.detailtousersname}}</option> 

use ng-options

<select ng-options="person.userswork person.name (objid, person) in persons"></select> 

assuming data array object in $scope.persons (sub out whatever)


Comments

Popular posts from this blog

c++ - Delete matches in OpenCV (Keypoints and descriptors) -

java - Could not locate OpenAL library -

sorting - opencl Bitonic sort with 64 bits keys -