Esempio n. 1
0
        public async Task <IActionResult> Index()
        {
            var configs = await _configurationDatasource.GetAllAsync();

            return(View(new HomeIndexModel
            {
                ConfigList = configs.Select(c => new ConfigModel
                {
                    Id = c.Id,
                    ApplicationName = c.ApplicationName,
                    IsActive = c.IsActive,
                    Name = c.Name,
                    Type = c.Type,
                    Value = c.Value
                }).ToList()
            }));
        }
Esempio n. 2
0
 public async Task <IActionResult> List()
 {
     return(Json(new { Result = await _configurationDatasource.GetAllAsync() }));
 }