/// <summary> /// Gets the specified request. /// </summary> /// <param name="request">The request.</param> /// <returns>CurrencyResponse.</returns> public CurrencyResponse GetCurrencies(CurrencyRequest request) { var response = new CurrencyResponse(); if (request.LoadOptions.Contains("Currencies")) { if (request.LoadOptions.Contains("IsActive")) { response.Currencies = CurrencyDao.GetCurrenciesByActive(); } else { response.Currencies = request.LoadOptions.Contains("CurrenciesIsMain") ? CurrencyDao.GetCurrenciesByIsMain() : CurrencyDao.GetCurrencies(); } } if (request.LoadOptions.Contains("Currency")) { response.Currency = request.LoadOptions.Contains("CurrencyCode") ? CurrencyDao.GetCurrenciesByCurrencyCode(request.CurrencyCode) : CurrencyDao.GetCurrency(request.CurrencyId); } return(response); }
/// <summary> /// Gets the account categories by is active. /// </summary> /// <param name="isActive">if set to <c>true</c> [is active].</param> /// <returns>List<AccountCategoryEntity>.</returns> public List <CurrencyEntity> GetCurrenciesByIsActive(bool isActive) { return(ICurrencyDao.GetCurrenciesByActive()); }