Exemple #1
0
        public async Task <IActionResult> GetExchangeRatesAsync(DateTime startDate, DateTime endDate, [FromQuery] Dictionary <string, string> currencyCodes)
        {
            _logger.LogInformation("HttpGet: GetExchangeRatesAsync started");
            var searchModel = new ExchangeRateSearcher()
            {
                currencyCodes = currencyCodes, endDate = endDate, startDate = startDate
            };
            var result = await _service.GetExchangeRatesVMAsync(searchModel);

            _logger.LogInformation("HttpGet: returned view model");
            return(Ok(result));
        }