예제 #1
0
 public ProductService(IContentLoader contentLoader, UrlResolver urlResolver, ILinksRepository linksRepository, ICurrentMarket currentMarket)
 {
     _contentLoader   = contentLoader;
     _urlResolver     = urlResolver;
     _linksRepository = linksRepository;
     _currentMarket   = currentMarket;
 }
예제 #2
0
 public LinksController(ILinksRepository repo, IMapper mapper)
 {
     _repo = repo ??
             throw new ArgumentNullException(nameof(repo));
     _mapper = mapper ??
               throw new ArgumentNullException(nameof(mapper));
 }
예제 #3
0
 public DataManager(IEntityBaseRepository entityBases, ILinksRepository links, IOurTeamRepository ourTeams, ITypesRepository types)
 {
     EntityBases = entityBases;
     Links       = links;
     OurTeams    = ourTeams;
     Types       = types;
 }
예제 #4
0
 public CartItemViewModelFactory(
     IContentLoader contentLoader,
     IPricingService pricingService,
     UrlResolver urlResolver,
     ICurrentMarket currentMarket,
     ICurrencyService currencyService,
     IPromotionService promotionService,
     AppContextFacade appContext,
     ILineItemCalculator lineItemCalculator,
     IProductService productService,
     IRelationRepository relationRepository,
     ILinksRepository linksRepository,
     ICartService cartService)
 {
     _contentLoader      = contentLoader;
     _pricingService     = pricingService;
     _urlResolver        = urlResolver;
     _currentMarket      = currentMarket;
     _currencyService    = currencyService;
     _promotionService   = promotionService;
     _appContext         = appContext;
     _lineItemCalculator = lineItemCalculator;
     _productService     = productService;
     _relationRepository = relationRepository;
     _cartService        = cartService;
     _linksRepository    = linksRepository;
 }
예제 #5
0
 public LinksViewerController(
     IHttpContextIdentifier identifier,
     ILinksRepository linksRepository)
 {
     _Identifier      = identifier ?? throw new ArgumentNullException(nameof(identifier));
     _LinksRepository = linksRepository ?? throw new ArgumentNullException(nameof(linksRepository));
 }
 public FeedsService(IMapper mapper, IGeneralUsersService generalUsersService, ILinksService linksService, IGeneralUsersRepository generalUsersRepository, ILinksRepository linksRepository)
 {
     _mapper = mapper;
     _generalUsersService    = generalUsersService;
     _linksService           = linksService;
     _generalUsersRepository = generalUsersRepository;
     _linksRepository        = linksRepository;
 }
예제 #7
0
 public VotingService(
     ILinksRepository linksRepository,
     IVotesRepository votesRepository,
     IUserRepository userRepository)
 {
     _linksRepository = linksRepository;
     _votesRepository = votesRepository;
     _userRepository  = userRepository;
 }
예제 #8
0
 public LinksController(ILinksRepository linksRepo, ITagsRepository tagsRepo, IMapper mapper)
 {
     _linksRepo = linksRepo ??
                  throw new ArgumentNullException(nameof(linksRepo));
     _tagsRepo = tagsRepo ??
                 throw new ArgumentNullException(nameof(tagsRepo));
     _mapper = mapper ??
               throw new ArgumentNullException(nameof(mapper));
 }
예제 #9
0
 public FindHelper(ReadOnlyPricingLoader priceLoader, ILinksRepository linksRepository, IContentLoader contentLoader, UrlResolver urlResolver, IPermanentLinkMapper permanentLinkMapper, ReferenceConverter referenceConverter, IPriceService priceService, IWarehouseInventoryService inventoryService)
 {
     _priceLoader         = priceLoader;
     _linksRepository     = linksRepository;
     _contentLoader       = contentLoader;
     _urlResolver         = urlResolver;
     _permanentLinkMapper = permanentLinkMapper;
     _referenceConverter  = referenceConverter;
     _priceService        = priceService;
     _inventoryService    = inventoryService;
 }
예제 #10
0
 //构造器注入
 public HomeController(IUserInfoRepository userInfoRepository,
                       ITagsRepository tagsRepository,
                       IArticleRepository articleRepository,
                       ILinksRepository linksRepository, IUnitOfWork unitOfWork)
 {
     _userInfoRepository = userInfoRepository;
     _tagsRepository     = tagsRepository;
     _articleRepository  = articleRepository;
     _linksRepository    = linksRepository;
     _unitOfWork         = unitOfWork;
 }
예제 #11
0
 public PromotionEntryService(
     ILinksRepository linksRepository,
     ICatalogSystem catalogSystem,
     IContentLoader contentLoader,
     IWarehouseInventoryService inventoryService,
     IWarehouseRepository warehouseRepository)
 {
     _contentLoader = contentLoader;
     _linksRepository = linksRepository;
     _catalogSystem = catalogSystem;
     _inventoryService = inventoryService;
     _warehouseRepository = warehouseRepository;
 }
예제 #12
0
 public PromotionEntryService(
     ILinksRepository linksRepository,
     ICatalogSystem catalogSystem,
     IContentLoader contentLoader,
     IInventoryService inventoryService,
     IWarehouseRepository warehouseRepository)
 {
     _contentLoader       = contentLoader;
     _linksRepository     = linksRepository;
     _catalogSystem       = catalogSystem;
     _inventoryService    = inventoryService;
     _warehouseRepository = warehouseRepository;
 }
예제 #13
0
        public static string GetUrl(this VariationContent variant, ILinksRepository linksRepository, UrlResolver urlResolver)
        {
            var productLink = variant.GetParentProducts(linksRepository).FirstOrDefault();
            if (productLink == null)
            {
                return string.Empty;
            }

            var urlBuilder = new UrlBuilder(urlResolver.GetUrl(productLink));

            if (variant.Code != null)
            {
                urlBuilder.QueryCollection.Add("variationCode", variant.Code);
            }
            
            return urlBuilder.ToString();
        }
예제 #14
0
        public static string GetUrl(this VariationContent variant, ILinksRepository linksRepository, UrlResolver urlResolver)
        {
            var productLink = variant.GetParentProducts(linksRepository).FirstOrDefault();

            if (productLink == null)
            {
                return(string.Empty);
            }

            var urlBuilder = new UrlBuilder(urlResolver.GetUrl(productLink));

            if (variant.Code != null)
            {
                urlBuilder.QueryCollection.Add("variationCode", variant.Code);
            }

            return(urlBuilder.ToString());
        }
예제 #15
0
        private EntryContentBase GetParent(CatalogContentBase content)
        {
            ILinksRepository linksRepository = ServiceLocator.Current.GetInstance <ILinksRepository>();
            IContentLoader   contentLoader   = ServiceLocator.Current.GetInstance <IContentLoader>();

            IEnumerable <Relation> parentRelations = linksRepository.GetRelationsByTarget(content.ContentLink);

            if (parentRelations.Any())
            {
                Relation firstRelation = parentRelations.FirstOrDefault();
                if (firstRelation != null)
                {
                    var parentProductContent = contentLoader.Get <EntryContentBase>(firstRelation.Source);
                    return(parentProductContent);
                }
            }
            return(null);
        }
예제 #16
0
 /// <summary>
 /// Class Constructor
 /// </summary>
 /// <param name="linksRepository">IoC resolution for our Repository class.</param>
 public ApiController(ILinksRepository linksRepository)
 {
     repo = linksRepository;
 }
 public LinksService(IGeneralUsersService generalUsersService, ILinksRepository linkRepository, IMapper mapper)
 {
     _generalUsersService = generalUsersService;
     _mapper         = mapper;
     _linkRepository = linkRepository;
 }
예제 #18
0
 public RedirectController(ILinksRepository linksRepository, IHttpContextAccessor accessor)
 {
     _repository = linksRepository;
     _accessor   = accessor;
 }
예제 #19
0
 public HomeController(ITasksRepository tasksRepository, ILinksRepository linksRepository)
 {
     this.TasksRepository = tasksRepository;
     this.LinksRepository = linksRepository;
 }
예제 #20
0
 public LinksService(ILinksRepository linksRepository)
 {
     _linksRepository = linksRepository;
 }
 public ShortLinkRedirectController(ILinksRepository linksRepository)
 {
     _LinksRepository = linksRepository ?? throw new ArgumentNullException(nameof(linksRepository));
 }
예제 #22
0
 public CreateCommentCommandHandler(ILinksRepository linksRepository, ICommentsRepository commentsRepository)
 {
     _linksRepository    = linksRepository;
     _commentsRepository = commentsRepository;
 }
예제 #23
0
 public GetLinkByIdHandler(ILinksRepository linksRepository, IMapper mapper)
 {
     _linksRepository = linksRepository;
     _mapper          = mapper;
 }
예제 #24
0
 public GetLinkRequestHandler(ILinksRepository linksRepository)
 {
     _linksRepository = linksRepository;
 }
예제 #25
0
 public OrdersController(OrdersContext context)
 {
     _ordersRepository   = new OrdersRepository(context);
     _productsRepository = new ProductsRepository(context);
     _linksRepository    = new LinksRepository(context);
 }
예제 #26
0
 public CreateLinkHandler(ILinksRepository linksRepository, ICommunityRepository communityRepository)
 {
     _linksRepository     = linksRepository;
     _communityRepository = communityRepository;
 }
예제 #27
0
 public MainController(ILinksRepository linksRepository, IApplicationSettings applicationSettings)
 {
     this.linksRepository     = linksRepository;
     this.applicationSettings = applicationSettings;
 }
예제 #28
0
 public LinkController()
 {
     _linksRepository = new LinksRepository();
 }
예제 #29
0
 public LinkController(ILinksRepository linksRepository)
 {
     _repository = linksRepository;
 }
예제 #30
0
 public DeleteLinkCommandHandler(ILinksRepository linksRepository)
 {
     _linksRepository = linksRepository;
 }
예제 #31
0
 public LinkApiController(ILinksRepository repository)
 {
     this.repository = repository;
 }
예제 #32
0
 public RedirectController(ILinksRepository linksRepository)
 {
     _repository = linksRepository;
 }