I'm trying to pass two parameters via view > controller 1 > $route > controller 2.
from view 1:
<td><a href="" ng-class="getGroups({{acnOrgId}}, {{row.NetworkOrgID}})">{{row.NetworkOrgFullName}}</a></td>
from controller 1:
$scope.getGroups = function (acnId, orgId) {
$location.path('/Groups/' + acnId +'/'+ orgId);
}
from my routeProvider:
$routeProvider.when('/Groups/:acnId/:orgId', {
templateUrl: 'Pages/acn/partials/groups.html',
controller: 'groupsController'
});
On my controller 2:
console.log($routeParams.acnId , $routeParams.orgId)
My results in Console.Log are: [object Object] 164
I can do this with a single param and I actually pass the id I want to pass.
What am I doing wrong?
Thanks in advance!