Esempio n. 1
0
        public OrderEditService(AbstractOmsDbContext dbContext,
                                IOrderValidator orderValidator,
                                IOrderItemCollectionValidator orderItemsValidator)
        {
            _dbContext = dbContext ?? throw new ArgumentNullException(nameof(dbContext));

            _orderValidator      = orderValidator ?? throw new ArgumentNullException(nameof(orderValidator));
            _orderItemsValidator = orderItemsValidator ?? throw new ArgumentNullException(nameof(orderItemsValidator));
        }
Esempio n. 2
0
        public OrderService(AbstractOmsDbContext dbContext,
                            IOrderValidator orderValidator,
                            IOrderItemCollectionValidator orderItemsValidator,
                            IEmailTemplate emailTemplate,
                            IEmail email)
        {
            _dbContext = dbContext ?? throw new ArgumentNullException(nameof(dbContext));

            _orderValidator      = orderValidator ?? throw new ArgumentNullException(nameof(orderValidator));
            _orderItemsValidator = orderItemsValidator ?? throw new ArgumentNullException(nameof(orderItemsValidator));

            _emailTemplate = emailTemplate ?? throw new ArgumentNullException(nameof(emailTemplate));
            _email         = email ?? throw new ArgumentNullException(nameof(email));
        }