Reputation: 1014
When you have a table using md-data-table, How do you get the data for a particular row. Basically each row has a menu button and once they click on that button the data in that row should be saved in a variable:
Upvotes: 0
Views: 320
Reputation: 167
html :
<td md-cell>
<label>{{item.count}}</label>
<i ng-click="setSomeVar(item)">you_icon</i>
</td>
method in controller :
$scope.setSomeVar = function(item)
{
$scope.someVar = item.count;
}
Upvotes: 1