Example #1
0
        public PdfService(IOrderViewClient orderViewClient, IFileClient fileClient, IKenticoResourceService resources, IKenticoDocumentProvider documents, IKenticoLogger logger)
        {
            if (orderViewClient == null)
            {
                throw new ArgumentNullException(nameof(orderViewClient));
            }
            if (fileClient == null)
            {
                throw new ArgumentNullException(nameof(fileClient));
            }
            if (resources == null)
            {
                throw new ArgumentNullException(nameof(resources));
            }
            if (documents == null)
            {
                throw new ArgumentNullException(nameof(documents));
            }
            if (logger == null)
            {
                throw new ArgumentNullException(nameof(logger));
            }

            this.orderViewClient = orderViewClient;
            this.fileClient      = fileClient;
            this.resources       = resources;
            this.documents       = documents;
            this.logger          = logger;
        }
Example #2
0
        public OrderListService(IMapper mapper, IOrderViewClient orderClient, IKenticoUserProvider kenticoUsers,
                                IKenticoResourceService kenticoResources, IKenticoSiteProvider site, IKenticoOrderProvider order,
                                IKenticoDocumentProvider documents, IKenticoPermissionsProvider permissions, IKenticoLogger logger, IKenticoAddressBookProvider kenticoAddressBook)
        {
            if (mapper == null)
            {
                throw new ArgumentNullException(nameof(mapper));
            }
            if (orderClient == null)
            {
                throw new ArgumentNullException(nameof(orderClient));
            }
            if (kenticoUsers == null)
            {
                throw new ArgumentNullException(nameof(kenticoUsers));
            }
            if (kenticoResources == null)
            {
                throw new ArgumentNullException(nameof(kenticoResources));
            }
            if (site == null)
            {
                throw new ArgumentNullException(nameof(site));
            }
            if (order == null)
            {
                throw new ArgumentNullException(nameof(order));
            }
            if (permissions == null)
            {
                throw new ArgumentNullException(nameof(permissions));
            }
            if (documents == null)
            {
                throw new ArgumentNullException(nameof(documents));
            }
            if (logger == null)
            {
                throw new ArgumentNullException(nameof(logger));
            }
            if (kenticoAddressBook == null)
            {
                throw new ArgumentNullException(nameof(kenticoAddressBook));
            }

            _mapper             = mapper;
            _orderClient        = orderClient;
            _kenticoUsers       = kenticoUsers;
            _kenticoResources   = kenticoResources;
            _site               = site;
            _order              = order;
            _permissions        = permissions;
            _logger             = logger;
            _kenticoAddressBook = kenticoAddressBook;

            _orderDetailUrl = documents.GetDocumentUrl(kenticoResources.GetSettingsKey("KDA_OrderDetailUrl"));
        }
Example #3
0
        public OrderDetailService(IMapper mapper,
                                  IOrderViewClient orderViewClient,
                                  IMailingListClient mailingClient,
                                  IKenticoOrderProvider kenticoOrder,
                                  IShoppingCartProvider shoppingCart,
                                  IKenticoProductsProvider products,
                                  IKenticoUserProvider kenticoUsers,
                                  IKenticoResourceService resources,
                                  IKenticoLogger kenticoLog,
                                  IKenticoLocalizationProvider localization,
                                  IKenticoPermissionsProvider permissions,
                                  IKenticoBusinessUnitsProvider businessUnits
                                  )
        {
            if (mapper == null)
            {
                throw new ArgumentNullException(nameof(mapper));
            }
            if (orderViewClient == null)
            {
                throw new ArgumentNullException(nameof(orderViewClient));
            }
            if (mailingClient == null)
            {
                throw new ArgumentNullException(nameof(mailingClient));
            }
            if (kenticoOrder == null)
            {
                throw new ArgumentNullException(nameof(kenticoOrder));
            }
            if (shoppingCart == null)
            {
                throw new ArgumentNullException(nameof(shoppingCart));
            }
            if (products == null)
            {
                throw new ArgumentNullException(nameof(products));
            }
            if (kenticoUsers == null)
            {
                throw new ArgumentNullException(nameof(kenticoUsers));
            }
            if (resources == null)
            {
                throw new ArgumentNullException(nameof(resources));
            }
            if (kenticoLog == null)
            {
                throw new ArgumentNullException(nameof(kenticoLog));
            }
            if (localization == null)
            {
                throw new ArgumentNullException(nameof(localization));
            }
            if (permissions == null)
            {
                throw new ArgumentNullException(nameof(permissions));
            }
            if (businessUnits == null)
            {
                throw new ArgumentNullException(nameof(businessUnits));
            }

            this.mapper          = mapper;
            this.orderViewClient = orderViewClient;
            this.kenticoOrder    = kenticoOrder;
            this.shoppingCart    = shoppingCart;
            this.products        = products;
            this.kenticoUsers    = kenticoUsers;
            this.resources       = resources;
            this.mailingClient   = mailingClient;
            this.kenticoLog      = kenticoLog;
            this.localization    = localization;
            this.permissions     = permissions;
            this.businessUnits   = businessUnits;
        }