add search and pagination