2014-11-12 2 views
0

동시에 입력 할 모델을 바인딩하는 데 문제가 있습니다. 모델이 드롭 다운에서 선택되면 입력 값이 변경됩니다. 그러나 입력 된 입력 값이 목록의 일부 값과 같으면 드롭 다운이 변경되지 않습니다.입력을 바인딩하고 하나의 ng-model을 선택하십시오.

Example on Plunker 드롭 다운 메뉴에서

<select 
    ng-model="Choice.SelectedOption"     
    ng-options="choice.ID as choice.Name for choice in Choice.Options"> 
</select> 

{{Choice.SelectedOption.ID}} 
input model <input type="text" ng-model="Choice.SelectedOption"> 
input value {{ Choice.SelectedOption }} 

변경 모델은 다음 (그것의 사용자 ID의)

답변