public async Task <IActionResult> Index()
        {
            var readProjectsRequest = new ReadProjectsRequest();
            var response            = await _projectApplicationService.Handle(readProjectsRequest);

            return(View(response));
        }
Esempio n. 2
0
        public async Task <IEnumerable <ProjectResponse> > Handle(ReadProjectsRequest request)
        {
            var projects = await _projectRepository.ReadAll();

            var response = projects.Select(project => project.Adapt <ProjectResponse>());

            return(response);
        }