public virtual async Task <IActionResult> Index() { if (DataSettingsHelper.DatabaseIsInstalled()) { return(RedirectToRoute("HomePage")); } var installed = await _cacheManager.GetAsync <bool>("Installed"); if (installed) { return(View(new InstallModel() { Installed = true })); } var model = new InstallModel { AdminEmail = "*****@*****.**", InstallSampleData = false, DatabaseConnectionString = "", DataProvider = "mongodb", }; foreach (var lang in _locService.GetAvailableLanguages()) { model.AvailableLanguages.Add(new SelectListItem { Value = Url.Action("ChangeLanguage", "Install", new { language = lang.Code }), Text = lang.Name, Selected = _locService.GetCurrentLanguage().Code == lang.Code, }); } //prepare collation list foreach (var col in _locService.GetAvailableCollations()) { model.AvailableCollation.Add(new SelectListItem { Value = col.Value, Text = col.Name, Selected = _locService.GetCurrentLanguage().Code == col.Value, }); } return(View(model)); }