add pagination index on click