model for the pagination

put your query to the pagination what you want