protected virtual void Dispose(bool disposing) { if (disposing) { // Free managed resources if (productRepository != null) { productRepository.Dispose(); productRepository = null; } if (saleModalityProductRepository != null) { saleModalityProductRepository.Dispose(); saleModalityProductRepository = null; } if (productDocumentService != null) { productDocumentService.Dispose(); productDocumentService = null; } if (customerProductRepository != null) { customerProductRepository.Dispose(); customerProductRepository = null; } if (saleModalityProductMarginRepository != null) { saleModalityProductMarginRepository.Dispose(); saleModalityProductMarginRepository = null; } } }
public ProductService( IProductRepository productRepo, ISaleModalityProductRepository saleModalityProductRepo, IProductDocumentService productDocumentServ, ICustomerProductRepository customerProductRepo, ISaleModalityProductMarginRepository saleModalityProductMarginRepo) { productRepository = productRepo; saleModalityProductRepository = saleModalityProductRepo; productDocumentService = productDocumentServ; customerProductRepository = customerProductRepo; saleModalityProductMarginRepository = saleModalityProductMarginRepo; }
protected override void Dispose(bool disposing) { if (disposing) { if (saleModalityRepository != null) { saleModalityRepository.Dispose(); saleModalityRepository = null; } if (saleModalityProductRepository != null) { saleModalityProductRepository.Dispose(); saleModalityProductRepository = null; } } base.Dispose(disposing); }
public ProductQuoteApiController(IProductQuoteService productQuoteServ, IProductQuoteRepository productQuoteRepo, IProductRepository productRepo, ISaleModalityRepository saleModalityRepo, IGeographicAreaRepository geographicAreaRepo, ISaleModalityProductRepository saleModalityProductRepo, IGeographicAreaTransportTypeRepository geographicAreaTransportTypeRepo, ICreditRatingPaymentDeadlineRepository creditRatingPaymentDeadlineRepo, IExchangeTypeRepository exchangeTypeRepo, IStockTimeRepository stockTimeRepo, IDeliveryAmountRepository deliveryAmountRepo, ICustomerProductRepository customerProductRepo, ICustomerRepository customerRepo, IGlobalVariableRepository globalVariableRepo, ILogRecordRepository logRecordRepo, ISalesChannelUserRepository salesChannelUserRepo) { productQuoteService = productQuoteServ; productQuoteRepository = productQuoteRepo; productRepository = productRepo; saleModalityRepository = saleModalityRepo; geographicAreaRepository = geographicAreaRepo; saleModalityProductRepository = saleModalityProductRepo; geographicAreaTransportTypeRepository = geographicAreaTransportTypeRepo; creditRatingPaymentDeadlineRepository = creditRatingPaymentDeadlineRepo; exchangeTypeRepository = exchangeTypeRepo; stockTimeRepository = stockTimeRepo; deliveryAmountRepository = deliveryAmountRepo; customerProductRepository = customerProductRepo; customerRepository = customerRepo; globalVariableRepository = globalVariableRepo; logRecordRepository = logRecordRepo; salesChannelUserRepository = salesChannelUserRepo; }
public ProductQuoteServiceBuilder() { _logger = new Logger(); _productRepository = new ProductRepository(_logger, new ProductDocumentRepository(_logger)); _saleModalityRepository = new SaleModalityRepository(_logger); _geographicAreaRepository = new GeographicAreaRepository(_logger); _saleModalityProductRepository = new SaleModalityProductRepository(_logger); _geographicAreaTransportTypeRepository = new GeographicAreaTransportTypeRepository(_logger); _creditRatingPaymentDeadlineRepository = new CreditRatingPaymentDeadlineRepository(_logger); _exchangeTypeRepository = new ExchangeTypeRepository(_logger); _stockTimeRepository = new StockTimeRepository(_logger); _deliveryAmountRepository = new DeliveryAmountRepository(_logger); _productQuoteRepository = new ProductQuoteRepository(_logger); _emailManager = new EmailManager(); _emailAccountRepository = new EmailAccountRepository(_logger); _adminUserRepository = new AdminUserRepository(); _applicationUserRepository = new ApplicationUserRepository(); _workflowMessageService = new WorkflowMessageService(_emailManager, _emailAccountRepository, _adminUserRepository, _applicationUserRepository); _pdfService = new PdfService(); _saleModalityCreditRatingRepository = new SaleModalityCreditRatingRepository(_logger); _globalVariableRepository = new GlobalVariableRepository(_logger); _customerOrderRepository = new CustomerOrderRepository(_logger); _customerRepository = new CustomerRepository(_logger); _transportTypeRepository = new TransportTypeRepository(_logger); _packagingRepository = new PackagingRepository(_logger); _rofexRepository = new RofexRepository(_logger); _paymentDeadlineRepository = new PaymentDeadlineRepository(_logger); _shipmentTrackingRepository = new ShipmentTrackingRepository(_logger); _customerProductRepository = new CustomerProductRepository(_logger); _logRecordRepository = new LogRecordRepository(); _customerOrderService = new CustomerOrderService(_customerOrderRepository, _workflowMessageService); _transportService = new TransportServices(_geographicAreaTransportTypeRepository); _marginServices = new MarginServices(); _wayOfExceptionRepository = new WayOfExceptionRepository(_logger); _wayOfExceptionServices = new WayOfExceptionServices(_wayOfExceptionRepository); _salesChannelUserRepository = new SalesChannelUserRepository(_logger); }
public SaleModalityProductApiController(ISaleModalityRepository saleModalityRepo, ISaleModalityProductRepository saleModalityProductRepo) { saleModalityRepository = saleModalityRepo; saleModalityProductRepository = saleModalityProductRepo; }
protected override void Dispose(bool disposing) { if (disposing) { if (productQuoteService != null) { productQuoteService.Dispose(); productQuoteService = null; } if (productQuoteRepository != null) { productQuoteRepository.Dispose(); productQuoteRepository = null; } if (productRepository != null) { productRepository.Dispose(); productRepository = null; } if (saleModalityRepository != null) { saleModalityRepository.Dispose(); saleModalityRepository = null; } if (geographicAreaRepository != null) { geographicAreaRepository.Dispose(); geographicAreaRepository = null; } if (saleModalityProductRepository != null) { saleModalityProductRepository.Dispose(); saleModalityProductRepository = null; } if (geographicAreaTransportTypeRepository != null) { geographicAreaTransportTypeRepository.Dispose(); geographicAreaTransportTypeRepository = null; } if (creditRatingPaymentDeadlineRepository != null) { creditRatingPaymentDeadlineRepository.Dispose(); creditRatingPaymentDeadlineRepository = null; } if (exchangeTypeRepository != null) { exchangeTypeRepository.Dispose(); exchangeTypeRepository = null; } if (stockTimeRepository != null) { stockTimeRepository.Dispose(); stockTimeRepository = null; } if (deliveryAmountRepository != null) { deliveryAmountRepository.Dispose(); deliveryAmountRepository = null; } if (customerProductRepository != null) { customerProductRepository.Dispose(); customerProductRepository = null; } if (customerRepository != null) { customerRepository.Dispose(); customerRepository = null; } if (globalVariableRepository != null) { globalVariableRepository.Dispose(); customerRepository = null; } if (logRecordRepository != null) { logRecordRepository.Dispose(); logRecordRepository = null; } if (salesChannelUserRepository != null) { salesChannelUserRepository.Dispose(); salesChannelUserRepository = null; } if (globalVariableRepository != null) { globalVariableRepository.Dispose(); globalVariableRepository = null; } } base.Dispose(disposing); }