Exemplo n.º 1
0
        public async Task <IActionResult> Index()
        {
            var accounts = await _managementService.GetAccounts();

            var viewModels = accounts.Select(x => new AccountViewModel
            {
                Id           = x.Id,
                Amount       = x.Amount,
                CurrencyName = GetCurrencyFullName(x.CurrencyCharCode),
            }).ToArray();

            return(View(viewModels));
        }