Beispiel #1
0
        public ServiceHttpClient(HttpClient client, SkrillSettings settings)
        {
            //configure client
            client.Timeout = TimeSpan.FromSeconds(settings.RequestTimeout ?? 10);
            client.DefaultRequestHeaders.Add(HeaderNames.UserAgent, Defaults.UserAgent);
            client.DefaultRequestHeaders.Add(HeaderNames.Accept, "*/*");

            _httpClient = client;
        }
Beispiel #2
0
 public ServiceManager(CurrencySettings currencySettings,
                       IActionContextAccessor actionContextAccessor,
                       IAddressService addressService,
                       ICountryService countryService,
                       ICurrencyService currencyService,
                       ICustomerService customerService,
                       IGenericAttributeService genericAttributeService,
                       ILanguageService languageService,
                       ILocalizationService localizationService,
                       ILogger logger,
                       IProductService productService,
                       IOrderService orderService,
                       IOrderTotalCalculationService orderTotalCalculationService,
                       IStateProvinceService stateProvinceService,
                       IStoreContext storeContext,
                       IShoppingCartService shoppingCartService,
                       IUrlHelperFactory urlHelperFactory,
                       IWebHelper webHelper,
                       IWorkContext workContext,
                       ServiceHttpClient httpClient,
                       SkrillSettings settings)
 {
     _currencySettings        = currencySettings;
     _actionContextAccessor   = actionContextAccessor;
     _addressService          = addressService;
     _countryService          = countryService;
     _currencyService         = currencyService;
     _customerService         = customerService;
     _genericAttributeService = genericAttributeService;
     _languageService         = languageService;
     _localizationService     = localizationService;
     _logger         = logger;
     _productService = productService;
     _orderService   = orderService;
     _orderTotalCalculationService = orderTotalCalculationService;
     _stateProvinceService         = stateProvinceService;
     _storeContext        = storeContext;
     _shoppingCartService = shoppingCartService;
     _urlHelperFactory    = urlHelperFactory;
     _webHelper           = webHelper;
     _workContext         = workContext;
     _httpClient          = httpClient;
     _settings            = settings;
 }