我有一个人物:
person = {};
person.city = {};
person.city.state = {};
首先选择州
<input type="text" class="form-control" ng-model="person.city.state" uib-typeahead="state as state.name for state in getState($viewValue)" >
后选择州选择
的城市<input type="text" class="form-control" ng-model="person.city" uib-typeahead="city as city.name for city in getCity($viewValue, person.city.state.id)" >
当我选择状态时,一切都没问题,但是城市输入获得价值&#39; [对象对象]&#39;选择状态后,如果我清理城市输入值来键入搜索,状态输入也是干净的。 有什么建议吗?