Added a service to manage the query and page. Also created a new controller for home.