Пример #1
0
        public IActionResult Index(SearchInputModel searchInputModel)
        {
            var searchText = searchInputModel.s;
            var filterText = searchInputModel.f;

            // Search
            var searchResult =
                _personSearchService.SearchPersonNames(searchText, filterText);

            // ViewModel
            var viewModel = new IndexViewModel();

            viewModel.AddSearchInputFromUser(searchInputModel);
            viewModel.AddPersonSearchResult(searchResult);

            // View
            return(View(viewModel));
        }