コード例 #1
0
 public StorefrontGraphUserContextBuilder(
     ILanguageProvider languageProvider,
     ICurrencyProvider currencyProvider)
 {
     _languageProvider = languageProvider;
     _currencyProvider = currencyProvider;
 }
コード例 #2
0
ファイル: FxMatrix.cs プロジェクト: biqueta/qwack
 public FxMatrix(ICurrencyProvider currencyProvider)
 {
     _currencyProvider = currencyProvider;
     SpotRates         = new Dictionary <Currency, double>();
     DiscountCurveMap  = new Dictionary <Currency, string>();
     FxPairDefinitions = new List <FxPair>();
 }
コード例 #3
0
        public AddressesController(
            IOrderService orderService,
            IPaymentService paymentService,
            IShoppingCart shoppingCart,
            IOrchardServices orchardServices,
            ICurrencyProvider currencyProvider,
            INwazetCommunicationService nwazetCommunicationService,
            IWorkContextAccessor workContextAccessor,
            IShapeFactory shapeFactory,
            ITransactionManager transactionManager,
            IContentManager contentManager,
            INotifier notifier,
            IProductPriceService productPriceService,
            IAddressConfigurationService addressConfigurationService,
            IEnumerable <IOrderAdditionalInformationProvider> orderAdditionalInformationProviders,
            IEnumerable <IValidationProvider> validationProvider)
        {
            _orderService               = orderService;
            _paymentService             = paymentService;
            _shoppingCart               = shoppingCart;
            _orchardServices            = orchardServices;
            _currencyProvider           = currencyProvider;
            _nwazetCommunicationService = nwazetCommunicationService;
            _workContextAccessor        = workContextAccessor;
            _shapeFactory               = shapeFactory;
            _transactionManager         = transactionManager;
            _contentManager             = contentManager;
            _notifier                            = notifier;
            _productPriceService                 = productPriceService;
            _addressConfigurationService         = addressConfigurationService;
            _orderAdditionalInformationProviders = orderAdditionalInformationProviders;
            _validationProvider                  = validationProvider;

            T = NullLocalizer.Instance;
        }
コード例 #4
0
        public static IPriceCurve GetPriceCurve(this TO_PriceCurve transportObject, ICurrencyProvider currencyProvider, ICalendarProvider calendarProvider)
        {
            if (transportObject.ConstantPriceCurve != null)
            {
                return new ConstantPriceCurve(transportObject.ConstantPriceCurve.Price, transportObject.ConstantPriceCurve.BuildDate, currencyProvider)
                       {
                           Currency = currencyProvider.GetCurrencySafe(transportObject.ConstantPriceCurve.Currency),
                           AssetId  = transportObject.ConstantPriceCurve.AssetId,
                           Name     = transportObject.ConstantPriceCurve.Name,
                       }
            }
            ;

            if (transportObject.BasicPriceCurve != null)
            {
                return(new BasicPriceCurve(transportObject.BasicPriceCurve, currencyProvider));
            }

            if (transportObject.BasisPriceCurve != null)
            {
                return(new BasisPriceCurve(transportObject.BasisPriceCurve, currencyProvider, calendarProvider));
            }

            if (transportObject.ContangoPriceCurve != null)
            {
                return(new ContangoPriceCurve(transportObject.ContangoPriceCurve, currencyProvider));
            }


            throw new Exception("Unable to build price curve");
        }
コード例 #5
0
        public PosServiceIntegration(
            IOrchardServices orchardServices,
            IEnumerable <IPosService> posServices,
            IShapeFactory shapeFactory,
            IOrderService orderService,
            ICurrencyProvider currencyProvider,
            IPaymentService paymentService,
            IWorkContextAccessor workContextAccessor,
            ICheckoutHelperService checkoutHelperService,
            IEnumerable <ICheckoutExtensionProvider> checkoutExtensionProviders)
        {
            _orchardServices            = orchardServices;
            _posServices                = posServices;
            _shapeFactory               = shapeFactory;
            _orderService               = orderService;
            _currencyProvider           = currencyProvider;
            _paymentService             = paymentService;
            _workContextAccessor        = workContextAccessor;
            _checkoutHelperService      = checkoutHelperService;
            _checkoutExtensionProviders = checkoutExtensionProviders;

            T = NullLocalizer.Instance;

            _paymentByTransactionId = new Dictionary <string, PaymentRecord>();
        }
コード例 #6
0
ファイル: ConstantVolSurface.cs プロジェクト: wy6688/qwack
 public ConstantVolSurface(TO_ConstantVolSurface transportObject, ICurrencyProvider currencyProvider)
     : this(transportObject.OriginDate, transportObject.Volatility)
 {
     Currency = currencyProvider.GetCurrency(transportObject.Currency);
     AssetId  = transportObject.AssetId;
     Name     = transportObject.Name;
 }
コード例 #7
0
 public OrderSslController(
     IOrderService orderService,
     IContentManager contentManager,
     IWorkContextAccessor wca,
     IShapeFactory shapeFactory,
     IAddressFormatter addressFormatter,
     INotifier notifier,
     IShoppingCart shoppingCart,
     IOrchardServices orchardServices,
     ICurrencyProvider currencyProvider,
     IEnumerable <ICartLifeCycleEventHandler> cartLifeCycleEventHandlers)
 {
     _orderService     = orderService;
     _contentManager   = contentManager;
     _wca              = wca;
     _shapeFactory     = shapeFactory;
     _addressFormatter = addressFormatter;
     _notifier         = notifier;
     _shoppingCart     = shoppingCart;
     _orderService     = orderService;
     T = NullLocalizer.Instance;
     _orchardServices            = orchardServices;
     _currencyProvider           = currencyProvider;
     _cartLifeCycleEventHandlers = cartLifeCycleEventHandlers;
 }
コード例 #8
0
        public ShoppingCartController(
            IShoppingCart shoppingCart,
            IShapeFactory shapeFactory,
            IContentManager contentManager,
            IWorkContextAccessor wca,
            IEnumerable <ICheckoutService> checkoutServices,
            IEnumerable <IShippingMethodProvider> shippingMethodProviders,
            IEnumerable <IExtraCartInfoProvider> extraCartInfoProviders,
            IWorkflowManager workflowManager,
            INotifier notifier,
            IEnumerable <IProductAttributeExtensionProvider> attributeExtensionProviders,
            ICurrencyProvider currencyProvider,
            ILocalStorageSettings localStorageSettings,
            IEnumerable <ICartLifeCycleEventHandler> cartLifeCycleEventHandlers)
        {
            _shippingMethodProviders = shippingMethodProviders;
            _shoppingCart            = shoppingCart;
            _shapeFactory            = shapeFactory;
            _contentManager          = contentManager;
            _wca = wca;
            _checkoutServices       = checkoutServices;
            _extraCartInfoProviders = extraCartInfoProviders;
            _notifier = notifier;
            _attributeExtensionProviders = attributeExtensionProviders;
            _currencyProvider            = currencyProvider;
            _localStorageSettings        = localStorageSettings;
            _cartLifeCycleEventHandlers  = cartLifeCycleEventHandlers;

            T = NullLocalizer.Instance;
        }
コード例 #9
0
        public AddressesController(
            IOrderService orderService,
            IPosServiceIntegration posServiceIntegration,
            IPaymentService paymentService,
            IShoppingCart shoppingCart,
            IOrchardServices orchardServices,
            ICurrencyProvider currencyProvider,
            INwazetCommunicationService nwazetCommunicationService,
            IWorkContextAccessor workContextAccessor,
            IShapeFactory shapeFactory,
            ITransactionManager transactionManager,
            IContentManager contentManager,
            INotifier notifier,
            IProductPriceService productPriceService)
        {
            _orderService               = orderService;
            _posServiceIntegration      = posServiceIntegration;
            _paymentService             = paymentService;
            _shoppingCart               = shoppingCart;
            _orchardServices            = orchardServices;
            _currencyProvider           = currencyProvider;
            _nwazetCommunicationService = nwazetCommunicationService;
            _workContextAccessor        = workContextAccessor;
            _shapeFactory               = shapeFactory;
            _transactionManager         = transactionManager;
            _contentManager             = contentManager;
            _notifier            = notifier;
            _productPriceService = productPriceService;

            T = NullLocalizer.Instance;
        }
コード例 #10
0
 public static IRuleBuilderOptions <T, string> MustBeCurrencyCode <T>(
     this IRuleBuilder <T, string> ruleBuilder, ICurrencyProvider currencyProvider)
 {
     return(ruleBuilder
            .Must(value => currencyProvider.GetCurrencies().Contains(value))
            .WithMessage("Not a valid currency code"));
 }
コード例 #11
0
 public RecurringOrderTemplateViewModelFactory(
     IOvertureClient overtureClient,
     ILocalizationProvider localizationProvider,
     IViewModelMapper viewModelMapper,
     ICountryService countryService,
     IComposerContext composerContext,
     IRecurringOrdersRepository recurringOrdersRepository,
     IAddressRepository addressRepository,
     IProductUrlProvider productUrlProvider,
     IProductPriceViewService productPriceViewService,
     IRecurringScheduleUrlProvider recurringScheduleUrlProvider,
     IRecurringOrderProgramViewModelFactory recurringOrderProgramViewModelFactory,
     IRecurringOrdersRepository recurringOrderRepository,
     ICurrencyProvider currencyProvider)
 {
     LocalizationProvider                  = localizationProvider ?? throw new ArgumentNullException(nameof(localizationProvider));
     ViewModelMapper                       = viewModelMapper ?? throw new ArgumentNullException(nameof(viewModelMapper));
     CountryService                        = countryService ?? throw new ArgumentNullException(nameof(countryService));
     ComposerContext                       = composerContext;
     RecurringOrdersRepository             = recurringOrdersRepository ?? throw new ArgumentNullException(nameof(recurringOrdersRepository));
     AddressRepository                     = addressRepository ?? throw new ArgumentNullException(nameof(addressRepository));
     ProductUrlProvider                    = productUrlProvider ?? throw new ArgumentNullException(nameof(productUrlProvider));
     ProductPriceViewService               = productPriceViewService ?? throw new ArgumentNullException(nameof(productPriceViewService));
     OvertureClient                        = overtureClient ?? throw new ArgumentNullException(nameof(overtureClient));
     RecurringScheduleUrlProvider          = recurringScheduleUrlProvider ?? throw new ArgumentNullException(nameof(recurringScheduleUrlProvider));
     RecurringOrderProgramViewModelFactory = recurringOrderProgramViewModelFactory ?? throw new ArgumentNullException(nameof(recurringOrderProgramViewModelFactory));
     RecurringOrderRepository              = recurringOrderRepository ?? throw new ArgumentNullException(nameof(recurringOrderRepository));
     CurrencyProvider                      = currencyProvider ?? throw new ArgumentNullException(nameof(currencyProvider));
 }
コード例 #12
0
ファイル: FxPair.cs プロジェクト: zhangz/qwack
 public static FxPair FxPairFromString(this string pair, ICurrencyProvider currencyProvider, ICalendarProvider calendarProvider) => new FxPair
 {
     Domestic           = currencyProvider.GetCurrency(pair.Substring(0, 3)),
     Foreign            = currencyProvider.GetCurrency(pair.Substring(pair.Length - 3, 3)),
     SettlementCalendar = calendarProvider.Collection[pair.Substring(0, 3) + "+" + pair.Substring(pair.Length - 3, 3)],
     SpotLag            = 2.Bd()
 };
 public LocalPurchasingBookReportFacade(IServiceProvider serviceProvider, PurchasingDbContext dbContext)
 {
     this.serviceProvider = serviceProvider;
     this.dbContext       = dbContext;
     this.dbSet           = dbContext.Set <UnitReceiptNote>();
     _currencyProvider    = (ICurrencyProvider)serviceProvider.GetService(typeof(ICurrencyProvider));
 }
コード例 #14
0
 public CurrencySaveService(ICurrencyProvider currencyProvider, IRepository repository,
                            ILogger <CurrencySaveService> logger)
 {
     _currencyProvider = currencyProvider;
     _repository       = repository;
     _logger           = logger;
 }
コード例 #15
0
        public CatalogProfile(ICurrencyProvider currencyProvider)
        {
            Assert.ArgumentNotNull(currencyProvider, nameof(currencyProvider));

            this.CreateMap <Connect.BaseProduct, BaseProduct>()
            .ForMember(
                dest => dest.StockStatusName,
                opt => opt.MapFrom(src => src.StockStatus != null ? src.StockStatus.Name : null))
            .ForMember(
                dest => dest.CurrencySymbol,
                opt => opt.MapFrom(src => currencyProvider.GetCurrencySymbolByCode(src.CurrencyCode)));

            this.CreateMap <Connect.Product, Product>()
            .IncludeBase <Connect.BaseProduct, BaseProduct>();

            this.CreateMap <Connect.Variant, Variant>()
            .IncludeBase <Connect.BaseProduct, BaseProduct>()
            .ForMember(dest => dest.VariantId, opt => opt.MapFrom(src => src.Id));

            this.CreateMap <Item, Category>()
            .ForMember(dest => dest.SitecoreId, opt => opt.MapFrom(src => src["SitecoreId"]))
            .ForMember(dest => dest.Name, opt => opt.MapFrom(src => src["Name"]))
            .ForMember(dest => dest.DisplayName, opt => opt.MapFrom(src => src["DisplayName"]))
            .ForMember(dest => dest.Description, opt => opt.MapFrom(src => src["Description"]))
            .ForMember(
                dest => dest.ParentCatalogList,
                opt => opt.ResolveUsing <MultilistFieldResolver, string>(src => src["ParentCatalogList"]))
            .ForMember(
                dest => dest.ChildrenCategoryList,
                opt => opt.ResolveUsing <MultilistFieldResolver, string>(src => src["ChildrenCategoryList"]));
        }
コード例 #16
0
        public IPriceCurve Solve(List <AsianSwapStrip> instruments, List <DateTime> pillars, IIrCurve discountCurve, DateTime buildDate, ICurrencyProvider currencyProvider)
        {
            _currencyProvider    = currencyProvider;
            _curveInstruments    = instruments;
            _pillars             = pillars.ToArray();
            _numberOfInstruments = _curveInstruments.Count;
            _numberOfPillars     = pillars.Count;
            _discountCurve       = discountCurve;
            _buildDate           = buildDate;

            _currentGuess = Enumerable.Repeat(instruments.Average(x => x.Swaplets.Average(s => s.Strike)), _numberOfPillars).ToArray();
            _currentCurve = new SparsePriceCurve(_buildDate, _pillars, _currentGuess, SparsePriceCurveType.Coal, currencyProvider, null);
            _currentPVs   = ComputePVs();

            ComputeJacobian();

            for (var i = 0; i < MaxItterations; i++)
            {
                ComputeNextGuess();
                _currentCurve = new SparsePriceCurve(_buildDate, _pillars, _currentGuess, SparsePriceCurveType.Coal, _currencyProvider);

                _currentPVs = ComputePVs();
                if (_currentPVs.Max(x => System.Math.Abs(x)) < Tollerance)
                {
                    UsedItterations = i + 1;
                    break;
                }
                ComputeJacobian();
            }

            return(_currentCurve);
        }
コード例 #17
0
 public Actor(ICurrencyProvider currencyProvider, IRuleLibrary ruleLibrary)
 {
     Guid             = Guid.NewGuid();
     Data             = new ActorData();
     CurrencyProvider = currencyProvider;
     RuleLibrary      = ruleLibrary;
 }
コード例 #18
0
 public OrderDetailsViewModelFactory(
     ILocalizationProvider localizationProvider,
     IViewModelMapper viewModelMapper,
     ICountryService countryService,
     IProductUrlProvider productUrlProvider,
     ICartViewModelFactory cartViewModelFactory,
     IPaymentProviderFactory paymentProviderFactory,
     IShippingTrackingProviderFactory shippingTrackingProviderFactory,
     ITaxViewModelFactory taxViewModelFactory,
     ILineItemViewModelFactory lineItemViewModelFactory,
     IRewardViewModelFactory rewardViewModelFactory,
     ICurrencyProvider currencyProvider)
 {
     LocalizationProvider            = localizationProvider ?? throw new ArgumentNullException(nameof(localizationProvider));
     ViewModelMapper                 = viewModelMapper ?? throw new ArgumentNullException(nameof(viewModelMapper));
     CountryService                  = countryService ?? throw new ArgumentNullException(nameof(countryService));
     ProductUrlProvider              = productUrlProvider ?? throw new ArgumentNullException(nameof(productUrlProvider));
     CartViewModelFactory            = cartViewModelFactory ?? throw new ArgumentNullException(nameof(cartViewModelFactory));
     PaymentProviderFactory          = paymentProviderFactory ?? throw new ArgumentNullException(nameof(paymentProviderFactory));
     ShippingTrackingProviderFactory = shippingTrackingProviderFactory ?? throw new ArgumentNullException(nameof(shippingTrackingProviderFactory));
     TaxViewModelFactory             = taxViewModelFactory ?? throw new ArgumentNullException(nameof(taxViewModelFactory));
     LineItemViewModelFactory        = lineItemViewModelFactory ?? throw new ArgumentNullException(nameof(lineItemViewModelFactory));
     RewardViewModelFactory          = rewardViewModelFactory ?? throw new ArgumentNullException(nameof(rewardViewModelFactory));
     CurrencyProvider                = currencyProvider ?? throw new ArgumentNullException(nameof(currencyProvider));
 }
コード例 #19
0
 public OrderMigrations(
     IContentManager contentManager,
     ICurrencyProvider currencyProvider)
 {
     _contentManager   = contentManager;
     _currencyProvider = currencyProvider;
 }
コード例 #20
0
 private static AsianSwap GetAsianSwap(this TO_AsianSwap transportObject, ICurrencyProvider currencyProvider, ICalendarProvider calendarProvider) => new AsianSwap
 {
     TradeId            = transportObject.TradeId,
     Notional           = transportObject.Notional,
     Direction          = transportObject.Direction,
     AverageStartDate   = transportObject.AverageStartDate,
     AverageEndDate     = transportObject.AverageEndDate,
     FixingDates        = transportObject.FixingDates,
     FixingCalendar     = calendarProvider.GetCalendarSafe(transportObject.FixingCalendar),
     PaymentCalendar    = calendarProvider.GetCalendarSafe(transportObject.PaymentCalendar),
     SpotLag            = new Frequency(transportObject.SpotLag),
     SpotLagRollType    = transportObject.SpotLagRollType,
     PaymentLag         = new Frequency(transportObject.PaymentLag),
     PaymentLagRollType = transportObject.PaymentLagRollType,
     PaymentDate        = transportObject.PaymentDate,
     PaymentCurrency    = currencyProvider.GetCurrencySafe(transportObject.PaymentCurrency),
     AssetFixingId      = transportObject.AssetFixingId,
     AssetId            = transportObject.AssetId,
     DiscountCurve      = transportObject.DiscountCurve,
     FxConversionType   = transportObject.FxConversionType,
     FxFixingDates      = transportObject.FxFixingDates,
     FxFixingId         = transportObject.FxFixingId,
     Strike             = transportObject.Strike,
     Counterparty       = transportObject.Counterparty,
     HedgingSet         = transportObject.HedgingSet,
     PortfolioName      = transportObject.PortfolioName,
 };
コード例 #21
0
ファイル: FxPair.cs プロジェクト: wy6688/qwack
 public FxPair(TO_FxPair transportObject, ICurrencyProvider currencyProvider, ICalendarProvider calendarProvider)
 {
     Foreign           = currencyProvider.GetCurrency(transportObject.Foreign);
     Domestic          = currencyProvider.GetCurrency(transportObject.Domestic);
     SpotLag           = new Frequency(transportObject.SpotLag);
     PrimaryCalendar   = calendarProvider.Collection[transportObject.PrimaryCalendar];
     SecondaryCalendar = calendarProvider.Collection[transportObject.SecondaryCalendar];
 }
 public UnitPaymentQuantityCorrectionNoteFacade(IServiceProvider serviceProvider, PurchasingDbContext dbContext)
 {
     this.serviceProvider = serviceProvider;
     this.dbContext       = dbContext;
     this.dbSet           = dbContext.Set <UnitPaymentCorrectionNote>();
     _cacheManager        = serviceProvider.GetService <IDistributedCache>();
     _currencyProvider    = serviceProvider.GetService <ICurrencyProvider>();
 }
コード例 #23
0
 public ContangoPriceCurve(TO_ContangoPriceCurve transportObject, ICurrencyProvider currencyProvider)
     : this(transportObject.BuildDate, transportObject.Spot, transportObject.SpotDate, transportObject.PillarDates, transportObject.Contangos,
            currencyProvider, transportObject.Basis, transportObject.PillarLabels)
 {
     AssetId  = transportObject.AssetId;
     Name     = transportObject.Name;
     Currency = currencyProvider.GetCurrencySafe(transportObject.Currency);
 }
コード例 #24
0
 public GridVolSurface(TO_GridVolSurface transportObject, ICurrencyProvider currencyProvider)
     : this(transportObject.OriginDate, transportObject.Strikes, transportObject.Expiries, transportObject.Volatilities, transportObject.StrikeType,
            transportObject.StrikeInterpolatorType, transportObject.TimeInterpolatorType, transportObject.TimeBasis, transportObject.PillarLabels)
 {
     Currency = currencyProvider.GetCurrency(transportObject.Currency);
     AssetId  = transportObject.AssetId;
     Name     = transportObject.Name;
 }
コード例 #25
0
        public OrderService(IContentManager contentManager, UrlHelper url, ICurrencyProvider currencyProvider)
        {
            _contentManager   = contentManager;
            _url              = url;
            _currencyProvider = currencyProvider;

            T = NullLocalizer.Instance;
        }
コード例 #26
0
 public TimeLadder(RiskMetric metric, int nScenarios, Calendar calendar, ICurrencyProvider currencyProvider, bool returnDifferential = true)
 {
     Metric             = metric;
     NScenarios         = nScenarios;
     Calendar           = calendar;
     _currencyProvider  = currencyProvider;
     ReturnDifferential = returnDifferential;
 }
コード例 #27
0
 public TaxViewModelFactory(IViewModelMapper viewModelMapper,
                            ILocalizationProvider localizationProvider,
                            ICurrencyProvider currencyProvider)
 {
     ViewModelMapper      = viewModelMapper ?? throw new ArgumentNullException(nameof(viewModelMapper));
     LocalizationProvider = localizationProvider ?? throw new ArgumentNullException(nameof(localizationProvider));
     CurrencyProvider     = currencyProvider ?? throw new ArgumentNullException(nameof(currencyProvider));
 }
コード例 #28
0
ファイル: FxMatrix.cs プロジェクト: wy6688/qwack
 public FxMatrix(TO_FxMatrix transportObject, ICurrencyProvider currencyProvider, ICalendarProvider calendarProvider) : this(currencyProvider)
 {
     BaseCurrency      = currencyProvider.GetCurrency(transportObject.BaseCurrency);
     BuildDate         = transportObject.BuildDate;
     SpotRates         = transportObject.SpotRates.ToDictionary(x => currencyProvider.GetCurrency(x.Key), y => y.Value);
     DiscountCurveMap  = transportObject.DiscountCurveMap.ToDictionary(x => currencyProvider.GetCurrency(x.Key), y => y.Value);
     FxPairDefinitions = transportObject.FxPairDefinitions.Select(x => new FxPair(x, currencyProvider, calendarProvider)).ToList();
 }
コード例 #29
0
ファイル: AssetFxModel.cs プロジェクト: biqueta/qwack
 public AssetFxModel(TO_AssetFxModel transportObject, ICurrencyProvider currencyProvider, ICalendarProvider calendarProvider)
     : this(transportObject.BuildDate, new FundingModel(transportObject.FundingModel, currencyProvider, calendarProvider))
 {
     _assetCurves      = transportObject.AssetCurves.ToDictionary(x => x.Key, x => x.Value.GetPriceCurve(currencyProvider, calendarProvider));
     _assetVols        = transportObject.AssetVols.ToDictionary(x => new VolSurfaceKey(x.Key, currencyProvider), y => VolSurfaceFactory.GetVolSurface(y.Value, currencyProvider));
     _fixings          = transportObject.Fixings?.ToDictionary(x => x.Key, x => (IFixingDictionary) new FixingDictionary(x.Value)) ?? new Dictionary <string, IFixingDictionary>();
     CorrelationMatrix = transportObject.CorrelationMatrix == null?null:CorrelationMatrixFactory.GetCorrelationMatrix(transportObject.CorrelationMatrix);
 }
コード例 #30
0
 public OnSitePOSPaymentProvider(ILookupService lookupService, ICartViewModelFactory cartViewModelFactory,
                                 ILocalizationProvider localizationProvider, ICurrencyProvider currencyProvider)
 {
     CartViewModelFactory = cartViewModelFactory ?? throw new ArgumentNullException(nameof(cartViewModelFactory));
     LocalizationProvider = localizationProvider ?? throw new ArgumentNullException(nameof(localizationProvider));
     LookupService        = lookupService ?? throw new ArgumentNullException(nameof(lookupService));
     CurrencyProvider     = currencyProvider ?? throw new ArgumentNullException(nameof(currencyProvider));
 }
コード例 #31
0
        public OfflinePaymentController(
            IOrchardServices services,
            IClock clock,
            IPaymentService paymentService,
            ICurrencyProvider currencyProvider)
        {
            Services = services;
            _clock = clock;
            _paymentService = paymentService;
            _currencyProvider = currencyProvider;

            T = NullLocalizer.Instance;
        }
コード例 #32
0
 public PaymentController(
     IPaymentService paymentService,
     ICurrencyProvider currencyProvider,
     IPaypalApiService apiService,
     IClock clock,
     ISiteService siteService,
     IOrchardServices services) {
     _paymentService = paymentService;
     _currencyProvider = currencyProvider;
     _apiService = apiService;
     _clock = clock;
     _siteService = siteService;
     Services = services;
     T = NullLocalizer.Instance;
 }
コード例 #33
0
 public ExchangeRateController(ICurrencyProvider currencyProvider)
 {
     _currencyProvider = currencyProvider;
 }
コード例 #34
0
 public CurrencyController(ICurrencyProvider currencyProvider)
 {
     _currencyProvider = currencyProvider;
 }