ng-init is not calling second time when track by $index used
问题 html: <table> <tbody> <tr ng-repeat="row in Rows track by $index" ng-init="initUserDecision(row,$index)" > <td>{{employeeName}}</td> </tr> </table> <button id="change"/> controller: $scope.initUserDecision = function(row,index){ $scope.employeeName=row["name"]; } $scope.rows=[{id:1,name:'siva'},{id:2,name:'ram'}] //changing $scope.rows in button click event and used $scope.$apply as well angular.element(document).on("click", "#change", function () { $scope.rows=[{id:1,name:'ravi'},{id:2,name: