added pagination to tables