I am trying to achieve an expand and collapse row for ng-table, basically what we want is if you click on row it expands with more detail. Does anyone know how to achieve this?
Any help appreciated thanks
this is the the plunkr : http://plnkr.co/edit/xvAC9D6Do6rOkot1KwF4?p=preview
Hi Denny,
You have a small mistake in your template, you are closing the ‘end-TR’ on the wrong place.
Put something like this in:
<tr ng-repeat-start="user in $data">
<td ng-repeat="column in columns" ng-show="column.visible" sortable="column.field" style="text-align:center;">
{{user[column.field]}}
</td>
<td>
<button ng-if="user.expanded" ng-click="user.expanded = false">-</button>
<button ng-if="!user.expanded" ng-click="user.expanded = true">+</button>
</td>
</tr>
<tr ng-if="user.expanded" ng-repeat-end>
<td colspan="8">test</td>
</tr>
Regards
Sander
--
You received this message because you are subscribed to a topic in the Google Groups "AngularJS" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/angular/eBgQAM8ZSIA/unsubscribe.
To unsubscribe from this group and all its topics, send an email to angular+u...@googlegroups.com.
To post to this group, send email to ang...@googlegroups.com.
Visit this group at http://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.