Beispiel #1
0
        public IActionResult Index()
        {
            var model = new HomeViewModel();

            model.Questionnaires = _questionnaireService.GetQuestionnaires();
            return(View(model));
        }
        public async Task <ViewResult> Index()
        {
            var serviceUri = ConfigurationManager.AppSettings["QuestionnaireServiceUri"];

            var questionnaire = await _questionnaireService.GetQuestionnaires(serviceUri);

            var viewModel = _typeMapper.Convert <QuestionnaireModel, QuestionnaireViewModel>(questionnaire);

            return(View(viewModel));
        }