Re-usable Paging in AngularJS