【发布时间】:2017-06-20 23:33:08
【问题描述】:
我正在使用一个简单的 ng-repeat 来生成国家列表及其相应数据。每个列表中都有一个可以展开和折叠的隐藏行。
我正在努力让这个隐藏的行显示在ng-repeat 的每一行的底部。
HTML:
<tr ng-repeat="country in countries">
<td>{{country.name}}</td>
<td>{{country.population}}</td>
<td>{{country.currency}}</td>
<td>{{country.gpd}}</td>
<tr>
<p>Expand/collapse content</p>
</tr>
</tr>
输出:
France 61.3 EUR 54
Germany 81.5 EUR 82
Spain 12.7 EUR 78
UK 51.3 GBR 64
Expand/collapse content
所需的输出:
France 61.3 EUR 54
Expand/collapse content
Germany 81.5 EUR 82
Expand/collapse content
Spain 12.7 EUR 78
Expand/collapse content
UK 51.3 GBR 64
Expand/collapse content
【问题讨论】:
标签: html angularjs angularjs-directive html-table angularjs-ng-repeat