passed fetched data to view