When a button on my tr is clicked, I want to transfer the data within that tr to the next ng-controller. I've searched for a solution but it seems like I need to create an angular.module and connect the controllers together. Would it work with a localhost link instead? I'm completely stuck, any advice would be appreciated. Thank you in advance.
<div ng-controller="customersController">
<table>
<tr ng-click=getId(order) ng-repeat="x in Id">
<td>{{ x.firstname }}</td>
<td>{{ x.lastname}}</td>
</tr>
</table>
</div>
<div ng-controller="showInfo">
<p>id:{{ x.firstname}}</p>
<p>name:{{ x.lastname}}</p>
</div>
this is my script
function customersController($scope, $http) {
$scope.getId= function (order) {
};
$http.get("localhostlink")
.success(function (response) {
$scope.Id = response;});
}