I have the following accordion (using angular-ui-bootstrap) inside a paginated loop of elements:
<div data-ng-repeat="m in results">
<div class="stuff_in_the_middle">
<accordion id="accordion_{{$index+((currentPage-1)*20)+1}}" close-others="false">
<accordion-group>
[...stuff...]
</accordion-group>
<accordion-group>
[...stuff...]
</accordion-group>
<accordion-group>
[...stuff...]
</accordion-group>
</accordion>
<span id="toggle_{{$index+((currentPage-1)*20)+1}}" onClick="openAllGroups">Toggle groups</span>
</div>
</div>
I would like to know how to expand all accordion-group
elements at once with one click of the Toggle link. Is it possible?