add pagination to page index