我是 AngularJS 的新手,我猜有一个非常基本的问题。
我有一个下拉列表,根据选择,我希望下面的表格使用所属信息进行更新。
<div ng-controller="RightCtrl as right">
<select ng-model="right.selectedModule">
<option ng-repeat="module in right.modules" value="{{module.id}}">{{module.name}}
</option>
</select>
<table>
<thead>
<th>Right name</th>
<th>Description</th>
</thead>
<tbody ng-repeat="module in right.modules | filter: right.isCurrent">
<tr ng-repeat="selRight in module.rights">
<td right-id="{{selRight.id}}">{{selRight.name}}</td>
<td>
{{selRight.description}}
</td>
</tr>
</tbody>
</table>
</div>
我有一个 jsfiddle ( http://jsfiddle.net/EN3S9/ ) 并感谢每一个帮助。可能我还没有完全理解这个概念。