Get the <td> onclick value for another <td> of the same row with Angular
I would like to get the value of a data cell <td>if I click on another of <td>the same row.
<tr ng-repeat="x in names">
<td>{{ x.Name }}</td>
<td>{{ x.Country | uppercase }}</td>
</tr>
One way to solve it is for example http://jsfiddle.net/L60L3gv9/
$scope.getValueOfTD = function(x){
alert(x.Name);
}
But in my case there is no connection between my data cells. Is there a way to get this value with a standard function, for example?
$scope.getValueOfTD = function(){
}
Any decisions are ok
+4