Trying to pick up with an angulyar. It does not go into the selector to put the value from the model. For text data, dates, everything is okay. For a combo box, the value also prokibyvaetsya, but in the selector is not set, although if you then read the value from the selector (if the selector is not touched), then it is read the normal set, but not empty.
It looks like this in js:
$scope.genderList = [ { id: 0, name: 'Unknown' }, { id: 1, name: 'Male' }, { id: 2, name: 'Female' } ] $scope.getGender = function(gender) { return $scope.genderList[gender].name; } $scope.Person = { Id: 10, Gender: 1 }; B html:
<select data-ng-model="Person.Gender"> <option value="0">{{getGender(0)}}</option> <option value="1">{{getGender(1)}}</option> <option value="2">{{getGender(2)}}</option> </select>