Skip to content

Commit

Permalink
Merge 504f3f0 into 93b4846
Browse files Browse the repository at this point in the history
  • Loading branch information
codegaze committed Apr 25, 2014
2 parents 93b4846 + 504f3f0 commit 18e5945
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion ng-table.js
Original file line number Diff line number Diff line change
Expand Up @@ -505,6 +505,10 @@ var ngTableController = ['$scope', 'ngTableParams', '$timeout', function ($scope
sorting: sortingParams
});
};

$scope.getRowNumber = function (index){
return ($scope.params.page()-1) * $scope.params.count() + (index + 1);
}
}];
/**
* ngTable: Table + Angular JS
Expand Down Expand Up @@ -719,4 +723,4 @@ angular.module('ngTable').run(['$templateCache', function ($templateCache) {
$templateCache.put('ng-table/pager.html', '<div class="ng-cloak ng-table-pager"> <div ng-if="params.settings().counts.length" class="ng-table-counts btn-group pull-right"> <button ng-repeat="count in params.settings().counts" type="button" ng-class="{\'active\':params.count()==count}" ng-click="params.count(count)" class="btn btn-default"> <span ng-bind="count"></span> </button> </div> <ul class="pagination ng-table-pagination"> <li ng-class="{\'disabled\': !page.active}" ng-repeat="page in pages" ng-switch="page.type"> <a ng-switch-when="prev" ng-click="params.page(page.number)" href="">&laquo;</a> <a ng-switch-when="first" ng-click="params.page(page.number)" href=""><span ng-bind="page.number"></span></a> <a ng-switch-when="page" ng-click="params.page(page.number)" href=""><span ng-bind="page.number"></span></a> <a ng-switch-when="more" ng-click="params.page(page.number)" href="">&#8230;</a> <a ng-switch-when="last" ng-click="params.page(page.number)" href=""><span ng-bind="page.number"></span></a> <a ng-switch-when="next" ng-click="params.page(page.number)" href="">&raquo;</a> </li> </ul> </div> ');
}]);
return app;
}));
}));

0 comments on commit 18e5945

Please sign in to comment.