Пример #1
0
 public ViewHelpersController(IProductClientService productClientService, IGalardonClientService galardonClientService, IPymeClientService pymeClientService, IThemeClientService themeClientService)
 {
     _productClientService  = productClientService;
     _galardonClientService = galardonClientService;
     _pymeClientService     = pymeClientService;
     _themeClientService    = themeClientService;
 }
Пример #2
0
        //private readonly IHttpClientFactory _httpClientFactory;

        //public TestController(IHttpClientFactory httpClientFactory)
        //{
        //    _httpClientFactory = httpClientFactory;
        //}

        public async Task <IActionResult> Index([FromServices] IProductClientService productClientService)
        {
            var result = await productClientService.GetProduct();

            //HttpRequestMessage message = new HttpRequestMessage(HttpMethod.Get, "localhost.xxx");
            //message.Headers.Add("key1", "value1");
            //var httpClient = _httpClientFactory.CreateClient();
            //await httpClient.SendAsync(message);

            return(Content(result));
        }
Пример #3
0
 public CartsController(
     IProductClientService productClientService,
     ICartsMapperService cartsMapperService,
     ApplicationContext applicationContext,
     IHttpContextAccessor httpContextAccessor,
     ILogger <CartsController> logger)
 {
     _productClientService = productClientService;
     _cartsMapperService   = cartsMapperService;
     _applicationContext   = applicationContext;
     _httpContextAccessor  = httpContextAccessor;
     _logger = logger;
 }
Пример #4
0
 public HomeController(ILogger <HomeController> logger,
                       IProductClientService productClientService,
                       IOrderService orderService,
                       SimmonzDbContext context,
                       IUserClientService userClientService,
                       IConfiguration configuration,
                       ICategoryClientService categoryClientService
                       )
 {
     _categoryClientService = categoryClientService;
     _configuration         = configuration;
     _userClientService     = userClientService;
     _orderService          = orderService;
     _productClientService  = productClientService;
     _logger  = logger;
     _context = context;
 }
 public ProductController(
     IProductClientService productService,
     IImagesClientServices imagesClientServices,
     IStatisticsService statisticsService,
     ApplicationContext applicationContext,
     IHostingEnvironment hostingEnvironment,
     ICategoriesClientService categoriesClientService,
     IProductService productAdminService,
     ILogger <ProductController> logger)
 {
     _applicationContext      = applicationContext;
     _logger                  = logger;
     _productService          = productService;
     _imagesClientServices    = imagesClientServices;
     _hostingEnvironment      = hostingEnvironment;
     _statisticsService       = statisticsService;
     _categoriesClientService = categoriesClientService;
     _productAdminService     = productAdminService;
 }
Пример #6
0
 public OrderController(
     IUnitOfWork unitOfWork,
     IOrderService orderService,
     IOrderDetailsService orderDetailsService,
     IEmailSenderService emailSenderService,
     ILogger <OrderController> logger,
     IProductClientService productClientService,
     IStatusCartsService statusCartsService,
     IStatisticsService statisticsService,
     IHttpContextAccessor httpContextAccessor)
 {
     _unitOfWork          = unitOfWork;
     _orderService        = orderService;
     _orderDetailsService = orderDetailsService;
     _httpContextAccessor = httpContextAccessor;
     _emailSenderService  = emailSenderService;
     _statisticsService   = statisticsService;
     _logger = logger;
     _productClientService = productClientService;
     _statusCartsService   = statusCartsService;
 }
Пример #7
0
 public ProductsController(IProductClientService productClientService)
 {
     _productClientService = productClientService;
 }