Esempio n. 1
0
 public JobAdController(IEmployerJobAdsCommand employerJobAdsCommand, IAnonymousJobAdsCommand anonymousJobAdsCommand, IEmployerLogosCommand employerLogosCommand, IJobAdsCommand jobAdsCommand, IJobAdsQuery jobAdsQuery, IJobPostersQuery jobPostersQuery, IMemberJobAdViewsQuery memberJobAdViewsQuery, ICreditsQuery creditsQuery, IProductsQuery productsQuery, ICouponsQuery couponsQuery, IOrdersCommand ordersCommand, IOrdersQuery ordersQuery, IEmployerAllocationsCommand employerAllocationsCommand, IEmployerCreditsQuery employerCreditsQuery, IEmployerOrdersCommand employerOrdersCommand, IEmployerOrdersQuery employerOrdersQuery, ILocationQuery locationQuery, IIndustriesQuery industriesQuery, IAccountsManager accountsManager, ILoginCredentialsQuery loginCredentialsQuery, ILoginAuthenticationCommand loginAuthenticationCommand, IAuthenticationManager authenticationManager)
 {
     _employerJobAdsCommand      = employerJobAdsCommand;
     _anonymousJobAdsCommand     = anonymousJobAdsCommand;
     _employerLogosCommand       = employerLogosCommand;
     _jobAdsCommand              = jobAdsCommand;
     _jobAdsQuery                = jobAdsQuery;
     _jobPostersQuery            = jobPostersQuery;
     _memberJobAdViewsQuery      = memberJobAdViewsQuery;
     _creditsQuery               = creditsQuery;
     _productsQuery              = productsQuery;
     _couponsQuery               = couponsQuery;
     _ordersCommand              = ordersCommand;
     _ordersQuery                = ordersQuery;
     _employerAllocationsCommand = employerAllocationsCommand;
     _employerCreditsQuery       = employerCreditsQuery;
     _employerOrdersCommand      = employerOrdersCommand;
     _employerOrdersQuery        = employerOrdersQuery;
     _locationQuery              = locationQuery;
     _industriesQuery            = industriesQuery;
     _accountsManager            = accountsManager;
     _loginCredentialsQuery      = loginCredentialsQuery;
     _loginAuthenticationCommand = loginAuthenticationCommand;
     _authenticationManager      = authenticationManager;
 }
Esempio n. 2
0
 public OrdersController(IEmployerOrdersCommand employerOrdersCommand, IEmployerOrdersQuery employerOrdersQuery, IProductsQuery productsQuery, ICouponsQuery couponsQuery, ICreditsQuery creditsQuery)
 {
     _employerOrdersCommand = employerOrdersCommand;
     _employerOrdersQuery   = employerOrdersQuery;
     _productsQuery         = productsQuery;
     _couponsQuery          = couponsQuery;
     _creditsQuery          = creditsQuery;
 }
Esempio n. 3
0
 public static OrderDetailsModel GetOrderDetails(this IEmployerOrdersQuery employerOrdersQuery, ICreditsQuery creditsQuery, Order order, IEnumerable <Product> products)
 {
     return(new OrderDetailsModel
     {
         Order = order,
         Products = products.ToList(),
         OrderProducts = GetOrderProducts(order, products),
         Credits = creditsQuery.GetCredits().ToDictionary(c => c.Id, c => c),
     });
 }
Esempio n. 4
0
 public ProductsController(IEmployerOrdersQuery employerOrdersQuery, IProductsCommand productsCommand, IOrdersQuery ordersQuery, ICreditsQuery creditsQuery, IAllocationsQuery allocationsQuery, IRecruitersQuery recruitersQuery, IOrganisationsQuery organisationsQuery)
 {
     _employerOrdersQuery = employerOrdersQuery;
     _productsCommand     = productsCommand;
     _ordersQuery         = ordersQuery;
     _creditsQuery        = creditsQuery;
     _allocationsQuery    = allocationsQuery;
     _recruitersQuery     = recruitersQuery;
     _organisationsQuery  = organisationsQuery;
 }
Esempio n. 5
0
        public static OrderSummaryModel GetOrderSummary(this IEmployerOrdersQuery employerOrdersQuery, ICreditsQuery creditsQuery, IOrdersQuery ordersQuery, Order order, IEnumerable <Product> products, IRegisteredUser purchaser)
        {
            // Reorder the items by product name just to introduce some certainty.

            SortItems(creditsQuery, order, products);
            var receipt = ordersQuery.GetPurchaseReceipt(order.Id) as CreditCardReceipt;

            return(new OrderSummaryModel {
                OrderDetails = employerOrdersQuery.GetOrderDetails(creditsQuery, order, products), Receipt = receipt, Purchaser = purchaser
            });
        }
Esempio n. 6
0
 public NewOrderController(IPageflowEngine pageflowEngine, IEmployerOrdersCommand employerOrdersCommand, IEmployerOrdersQuery employerOrdersQuery, IProductsQuery productsQuery, ICreditsQuery creditsQuery, ICouponsQuery couponsQuery, IOrdersCommand ordersCommand, IOrdersQuery ordersQuery, IAccountsManager accountsManager, ILoginCredentialsQuery loginCredentialsQuery, ILoginAuthenticationCommand loginAuthenticationCommand, IAuthenticationManager authenticationManager, IIndustriesQuery industriesQuery)
     : base(Routes, pageflowEngine)
 {
     _employerOrdersCommand      = employerOrdersCommand;
     _employerOrdersQuery        = employerOrdersQuery;
     _productsQuery              = productsQuery;
     _creditsQuery               = creditsQuery;
     _couponsQuery               = couponsQuery;
     _ordersCommand              = ordersCommand;
     _ordersQuery                = ordersQuery;
     _accountsManager            = accountsManager;
     _loginCredentialsQuery      = loginCredentialsQuery;
     _loginAuthenticationCommand = loginAuthenticationCommand;
     _authenticationManager      = authenticationManager;
     _industriesQuery            = industriesQuery;
 }