Пример #1
0
        public MainViewModel(IImagineCupService imagineCupService,
            IPersonService personService,
            IDreamsparkService dreamsparkService,
            IBlogService blogService)
        {
            _personService = personService;
            _imagineCupService = imagineCupService;
            _dreamsparkService = dreamsparkService;
            _blogService = blogService;

            blogLoaded = teamLoaded = false;
            ProgressBarVisibility = "Visible";
            IsIndeterminate = "True";
            GridVisibility = "Collapsed";
            ProgressRingVisibility = "Visible";
            ProgressRingActive = "True";

            LoadPeople();
            LoadEntries();

            ImagineCupDescription = _imagineCupService.GetDescription();
            ImagineCupImage = _imagineCupService.GetImageUrl();
            Prizes = _imagineCupService.GetPrizes();
            DreamsparkDescription = _dreamsparkService.GetBriefDescription();
        }
Пример #2
0
        public static void CreateInitialData(this IAntlerConfigurator configurator, IBlogService blogService)
        {
            var userId = blogService.CreateUser(new CreatedUserDto()
                {
                    Name = "John",
                    Email = "*****@*****.**"
                });

            if (!userId.HasValue)
                throw new Exception("Problem while creating User");

            blogService.SavePost(new SavePostDto()
            {
                Title = "Great post about programming",
                Text = "Programming is a ...",
                AuthodId = userId.Value
            });

            blogService.SavePost(new SavePostDto()
            {
                Title = "Great post about fishing",
                Text = "Fishing is a ...",
                AuthodId = userId.Value
            });
        }
Пример #3
0
 public PostController(IPostService postService, IDashboardService dashboardService, IBlogService blogService, ILogger logger)
     : base(logger)
 {
     _postService = postService;
     _dashboardService = dashboardService;
     _blogService = blogService;
 }
Пример #4
0
 /// <summary>
 /// Initializes a new instance of the <see cref="BlogsApiContext" /> class.
 /// </summary>
 /// <param name="lifetimeScope">The lifetime scope.</param>
 /// <param name="tagService">The tag service.</param>
 /// <param name="blogService">The blog service.</param>
 /// <param name="authorService">The author service.</param>
 /// <param name="repository">The repository.</param>
 public BlogsApiContext(ILifetimeScope lifetimeScope, ITagService tagService, IBlogService blogService, IAuthorService authorService, IRepository repository = null)
     : base(lifetimeScope, repository)
 {
     this.tagService = tagService;
     this.blogService = blogService;
     this.authorService = authorService;
 }
 public BlogController(IAtomPubService atompub, IAnnotateService annotate, IBlogService blog)
   : base()
 {
   AtomPubService = atompub;
   AnnotateService = annotate;
   BlogService = blog;
 }
Пример #6
0
        public void SetUp()
        {
            _blogRepository = new Mock<IBlogRepository>();
            _entryRepository = new Mock<IEntryRepository>();

            _blogService = new BlogService(_blogRepository.Object, _entryRepository.Object);
        }
Пример #7
0
 public ArticleController(IBlogService blogService, IArticleService articleService, ITagService tagService, ICommentService commentService)
 {
     _blogService = blogService;
     _articleService = articleService;
     _tagService = tagService;
     _commentService = commentService;
 }
 public RobotsTxtManager(
     ISettingService settingService,
     ILocalizationService localizationService,
     LocalizationSettings localizationSettings,
     IStoreContext storeContext,
     ILanguageService languageService,
     IBlogService blogService,
     INewsService newsService,
     ICategoryService categoryService,
     IManufacturerService manufacturerService,
     ITopicService topicService,
     IVendorService vendorService,
     IProductService productService)
 {
     _settingService = settingService;
     _localizationService = localizationService;
     _localizationSettings = localizationSettings;
     _storeContext = storeContext;
     _languageService = languageService;
     _blogService = blogService;
     _newsService = newsService;
     _categoryService = categoryService;
     _manufacturerService = manufacturerService;
     _topicService = topicService;
     _vendorService = vendorService;
     _productService = productService;
     _storeId = _storeContext.CurrentStore.Id;
     _languages = _languageService.GetAllLanguages(storeId: _storeId);
 }
Пример #9
0
 public EntryController(IEntryService entryService, ICommentService commentService, IBlogService blogService, ITagService tagService)
 {
     _entryService = entryService;
     _commentService = commentService;
     _blogService = blogService;
     _tagService = tagService;
 }
Пример #10
0
        public BlogController(IBlogService blogService, 
            IWorkContext workContext,
            IStoreContext storeContext,
            IPictureService pictureService, 
            ILocalizationService localizationService,
            IDateTimeHelper dateTimeHelper,
            IWorkflowMessageService workflowMessageService, 
            IWebHelper webHelper,
            ICacheManager cacheManager, 
            ICustomerActivityService customerActivityService,
            IStoreMappingService storeMappingService,
            MediaSettings mediaSettings,
            BlogSettings blogSettings,
            LocalizationSettings localizationSettings, 
            CustomerSettings customerSettings,
            CaptchaSettings captchaSettings)
        {
            this._blogService = blogService;
            this._workContext = workContext;
            this._storeContext = storeContext;
            this._pictureService = pictureService;
            this._localizationService = localizationService;
            this._dateTimeHelper = dateTimeHelper;
            this._workflowMessageService = workflowMessageService;
            this._webHelper = webHelper;
            this._cacheManager = cacheManager;
            this._customerActivityService = customerActivityService;
            this._storeMappingService = storeMappingService;

            this._mediaSettings = mediaSettings;
            this._blogSettings = blogSettings;
            this._localizationSettings = localizationSettings;
            this._customerSettings = customerSettings;
            this._captchaSettings = captchaSettings;
        }
Пример #11
0
 public HomeController(IUserService userService, IRoleService roleService, ICommentService commentService, IBlogService blogService, IArticleService articleService)
 {
     this.userService = userService;
     this.roleService = roleService;
     this.commentService = commentService;
     this.blogService = blogService;
     this.articleService = articleService;
 }
Пример #12
0
        public AdminController(IOrchardServices services, IImportService importService, IBlogService blogService, IEnumerable<IBlogAssembler> assemblers) {
            Services = services;
            _importService = importService;
            _blogService = blogService;
            _assemblers = assemblers;

            T = NullLocalizer.Instance;
        }
 public SearchController(IArticleService articleService, ITagRepository tagRepository,
     IBlogService blogService, IUserService userService)
 {
     _articleService = articleService;
     _tagRepository = tagRepository;
     _blogService = blogService;
     _userService = userService;
 }
Пример #14
0
		public GetBlogPost(
						IBlogService blogService,
						IBlogPostService blogPostService
						)
		{
			_blogService = blogService;
			_blogPostService = blogPostService;
		}
Пример #15
0
 public BlogController(IOrchardServices services, IBlogService blogService, IBlogSlugConstraint blogSlugConstraint, IFeedManager feedManager, RouteCollection routeCollection) {
     _services = services;
     _blogService = blogService;
     _blogSlugConstraint = blogSlugConstraint;
     _feedManager = feedManager;
     _routeCollection = routeCollection;
     Logger = NullLogger.Instance;
 }
Пример #16
0
 public AtomController(IBlogService blogService, IPostService postService, IDashboardService dashboardService, ILogger logger, ISyndicationFeedService syndicationFeedService)
     : base(logger)
 {
     _blogService = blogService;
     _postService = postService;
     _dashboardService = dashboardService;
     _syndicationFeedService = syndicationFeedService;
 }
 public ArticleController(IUserService service, IBlogService blogService,
     IArticleService articleService, ICommentService commentService)
 {
     _userService = service;
     _blogService = blogService;
     _articleService = articleService;
     _commentService = commentService;
 }
Пример #18
0
 public AdministratorController(IBlogService blogService, IEntryService entryService, IUserService userService, ITagService tagService, ICommentService commentService)
 {
     _blogService = blogService;
     _entryService = entryService;
     _userService = userService;
     _tagService = tagService;
     _commentService = commentService;
 }
Пример #19
0
		internal static BlogPart GetBlog(IBlogService blogService)
		{
			var blogPart = blogService.Get(VersionOptions.Published).FirstOrDefault();
			if (blogPart == null)
				throw new FileNotFoundException();

			return blogPart;
		}
    public ManagementModule(IBlogService blogService) : base("/manage", blogService)
    {
      this.RequiresAuthentication();

      Get["/"] = _ => View["Index.spark", blogService.LoadAll()];
      Get["/approve/{id}"] = p => Approve(blogService, p);
                             
    }
        public DefaultModule(IBlogService blogService)
        {
            //Injection
            _blogService = blogService;

            //Routes
            Get["/"] = parameters => Default(parameters);
        }
Пример #22
0
 //public List<Tag> Tags { get; set; }
 public EntryListViewModel(IBlogService blogService, Guid blogID, int? page)
 {
     int pageSize = 5;
     int pageNumber = (page ?? 1);
     Entries = blogService.GetBlog(blogID).Entries.OrderByDescending(x => x.CreatedDate).ToPagedList(pageNumber, pageSize);
     BlogTitle = blogService.GetBlog(blogID).BlogName;
     BlogSubtitle = blogService.GetBlog(blogID).BlogSubtitle;
     BlogID = blogID;
 }
Пример #23
0
        public BlogViewModel(IBlogService blogService)
        {
            _blogService = blogService;

            ProgressBarVisibility = "Visible";
            IsIndeterminate = "True";
            
            LoadEntries();
        }
Пример #24
0
        public NewsModule(IBlogService blogService)
            : base("/news")
        {
            //Injection
            _blogService = blogService;

            //Routes
            Get["/"] = parameters => Default(parameters);
        }
 public ArticleController(IArticleService ars, IBlogService bs, ICommentService cs, ITagService ts, IProfileService ps, IUserService us)
 {
     artService = ars;
     blogService = bs;
     commentService = cs;
     tagService = ts;
     profileService = ps;
     userService = us;
 }
    public ProfileModule(IBlogService blogService) :base(blogService)
    {
      Get["/profile"] = _ => View["Index"];

      After += ctx =>
      {
        ctx.ViewBag.Active = "Profile";
      };
    }
Пример #27
0
 public HomeController(ITwitterService twitterService, IBlogService blogService)
 {
     this.twitterService = twitterService;
     this.blogService = blogService;
     organization = OrganizationRepository.GetDefaultOrganization(readOnly: true);
     Mapper.CreateMap<Organization, OrganizationDetailsModel>();
     Mapper.CreateMap<OrganizationSetting, OrganizationSettingModel>();
     Mapper.CreateMap<CauseTemplate, CauseTemplateDetailsModel>();
 }
    public PortfolioModule(IBlogService blogService) : base(blogService)
    {
      Get["/portfolio"] = _ => View["Index"];

      After += ctx =>
      {
        ctx.ViewBag.Active = "Portfolio";
      };
    }
 public RemoteBlogPublishingController(
     IOrchardServices services, 
     IBlogService blogService, 
     IRsdConstraint rsdConstraint,
     RouteCollection routeCollection) {
     _blogService = blogService;
     _rsdConstraint = rsdConstraint;
     _routeCollection = routeCollection;
     Logger = NullLogger.Instance;
 }
 public BackwardCompatibility2XController(IProductService productService,
     ICategoryService categoryService, IManufacturerService manufacturerService,
     INewsService newsService, IBlogService blogService)
 {
     this._productService = productService;
     this._categoryService = categoryService;
     this._manufacturerService = manufacturerService;
     this._newsService = newsService;
     this._blogService = blogService;
 }
Пример #31
0
 public SidebarViewComponent(IBlogService blog)
 {
     _blogService = blog;
 }
Пример #32
0
 public BlogController(IBlogService blog, IOptionsSnapshot <BlogSettings> settings, WebManifest manifest)
 {
     _blog     = blog;
     _settings = settings;
     _manifest = manifest;
 }
Пример #33
0
 public SearchController(IBlogService blogService, IElasticClient elasticClient, IOptionsSnapshot <BlogSettings> settings)
 {
     _blogService   = blogService;
     _elasticClient = elasticClient;
     _settings      = settings;
 }
Пример #34
0
 public void SetUp()
 {
     _blogService = new BlogService(new CatalogSettings(), null, null, null, new TestCacheManager());
 }
Пример #35
0
 public BlogController(IBlogService blogService, IAuthozirationUtility securityUtility)
 {
     _blogService     = blogService;
     _securityUtility = securityUtility;
 }
 public BlogController(IBlogService blogService, IUserService userService, IArticleService articleService)
 {
     this._blogService    = blogService;
     this._userService    = userService;
     this._articleService = articleService;
 }
Пример #37
0
 public BlogController(ILogger <BlogController> logger,
                       IBlogService blogService)
 {
     _logger      = logger;
     _blogService = blogService;
 }
Пример #38
0
 public LayoutService(IBlogService blog, BlogDataContext dataContext) : base(blog, new LayoutDBRepository(dataContext))
 {
 }
 public RobotsController(IBlogService blog, IOptionsSnapshot <BlogSettings> settings, WebManifest manifest)
 {
     this.blog     = blog;
     this.settings = settings;
     this.manifest = manifest;
 }
Пример #40
0
 public MetaWeblogService(IBlogService blog, IConfiguration config, IHttpContextAccessor context)
 {
     _blog    = blog;
     _config  = config;
     _context = context;
 }
Пример #41
0
 protected RecordRepoBasedService(IBlogService blogService, TRepo repository)
 {
     Repository  = repository;
     BlogService = blogService;
 }
Пример #42
0
 public AdminSearchController(IProductService productService, ICategoryService categoryService, IManufacturerService manufacturerService,
                              ITopicService topicService, INewsService newsService, IBlogService blogService, ICustomerService customerService, IOrderService orderService,
                              AdminSearchSettings adminSearchSettings, ILocalizationService localizationService, IWorkContext workContext)
 {
     this._productService      = productService;
     this._categoryService     = categoryService;
     this._manufacturerService = manufacturerService;
     this._topicService        = topicService;
     this._newsService         = newsService;
     this._blogService         = blogService;
     this._customerService     = customerService;
     this._orderService        = orderService;
     this._adminSearchSettings = adminSearchSettings;
     this._localizationService = localizationService;
     this._workContext         = workContext;
 }
Пример #43
0
 public BlogApiController(IBlogService blogService, IAuthenticationService <int> authService,
                          ILogger <BlogApiController> logger) : base(logger)
 {
     _authenticationService = authService;
     _blogService           = blogService;
 }
Пример #44
0
 public PostsModel(ILogger <AdminModel> logger, IAuthService authService, ITextMapService textMapServic, IBlogService blogService,
                   IMemoryCache cache)
     : base(logger, authService, textMapServic)
 {
     _blogService = blogService;
     _cache       = cache;
 }
Пример #45
0
 public RobotsController(IBlogService blog, ISettingsService settings)
 {
     _blog     = blog;
     _settings = settings;
 }
Пример #46
0
 public BlogController(IBlogService service) : base(service)
 {
     _service = service;
 }
Пример #47
0
 public BlogsController(IUserService userService, IBlogService blogService)
 {
     _userService = userService;
     _blogService = blogService;
 }
Пример #48
0
 public void SetUp()
 {
     _blogService = new BlogService(_mockBlogRepository.Object);
     TestData     = new DeleteBlogAsync_TestData();
     Id           = TestData.Id;
 }
Пример #49
0
 public BlogController(IBlogService blog, IOptionsSnapshot <BlogSettings> settings)
 {
     _blog     = blog;
     _settings = settings;
 }
Пример #50
0
 public ImagesController(IBlogService blogService)
 {
     _blogService = blogService;
 }
Пример #51
0
 public KiwiUserServices(IBlogService blogService)
 {
     _blogService = blogService;
 }
Пример #52
0
 public AdminMenu(IBlogService blogService)
 {
     _blogService = blogService;
 }
Пример #53
0
 // TODO: inject BlogService
 public BlogsController(IBlogService blogService)
 {
     _blogService = blogService;
 }
 public CommonModelFactory(BlogSettings blogSettings,
                           CaptchaSettings captchaSettings,
                           CatalogSettings catalogSettings,
                           CommonSettings commonSettings,
                           CustomerSettings customerSettings,
                           DisplayDefaultFooterItemSettings displayDefaultFooterItemSettings,
                           ForumSettings forumSettings,
                           IActionContextAccessor actionContextAccessor,
                           IBlogService blogService,
                           ICategoryService categoryService,
                           ICurrencyService currencyService,
                           ICustomerService customerService,
                           IForumService forumService,
                           IGenericAttributeService genericAttributeService,
                           IHttpContextAccessor httpContextAccessor,
                           ILanguageService languageService,
                           ILocalizationService localizationService,
                           IManufacturerService manufacturerService,
                           INewsService newsService,
                           INopFileProvider fileProvider,
                           IPageHeadBuilder pageHeadBuilder,
                           IPermissionService permissionService,
                           IPictureService pictureService,
                           IProductService productService,
                           IProductTagService productTagService,
                           IShoppingCartService shoppingCartService,
                           ISitemapGenerator sitemapGenerator,
                           IStaticCacheManager staticCacheManager,
                           IStoreContext storeContext,
                           IThemeContext themeContext,
                           IThemeProvider themeProvider,
                           ITopicService topicService,
                           IUrlHelperFactory urlHelperFactory,
                           IUrlRecordService urlRecordService,
                           IWebHelper webHelper,
                           IWorkContext workContext,
                           LocalizationSettings localizationSettings,
                           MediaSettings mediaSettings,
                           NewsSettings newsSettings,
                           SitemapSettings sitemapSettings,
                           SitemapXmlSettings sitemapXmlSettings,
                           StoreInformationSettings storeInformationSettings,
                           VendorSettings vendorSettings)
 {
     _blogSettings     = blogSettings;
     _captchaSettings  = captchaSettings;
     _catalogSettings  = catalogSettings;
     _commonSettings   = commonSettings;
     _customerSettings = customerSettings;
     _displayDefaultFooterItemSettings = displayDefaultFooterItemSettings;
     _forumSettings           = forumSettings;
     _actionContextAccessor   = actionContextAccessor;
     _blogService             = blogService;
     _categoryService         = categoryService;
     _currencyService         = currencyService;
     _customerService         = customerService;
     _forumService            = forumService;
     _genericAttributeService = genericAttributeService;
     _httpContextAccessor     = httpContextAccessor;
     _languageService         = languageService;
     _localizationService     = localizationService;
     _manufacturerService     = manufacturerService;
     _newsService             = newsService;
     _fileProvider            = fileProvider;
     _pageHeadBuilder         = pageHeadBuilder;
     _permissionService       = permissionService;
     _pictureService          = pictureService;
     _productService          = productService;
     _productTagService       = productTagService;
     _shoppingCartService     = shoppingCartService;
     _sitemapGenerator        = sitemapGenerator;
     _staticCacheManager      = staticCacheManager;
     _storeContext            = storeContext;
     _themeContext            = themeContext;
     _themeProvider           = themeProvider;
     _topicService            = topicService;
     _urlHelperFactory        = urlHelperFactory;
     _urlRecordService        = urlRecordService;
     _webHelper                = webHelper;
     _workContext              = workContext;
     _mediaSettings            = mediaSettings;
     _localizationSettings     = localizationSettings;
     _newsSettings             = newsSettings;
     _sitemapSettings          = sitemapSettings;
     _sitemapXmlSettings       = sitemapXmlSettings;
     _storeInformationSettings = storeInformationSettings;
     _vendorSettings           = vendorSettings;
 }
Пример #55
0
 public DeleteModel(IBlogService blogService)
 {
     _blogService = blogService;
 }
Пример #56
0
 public BlogController(IBlogService blogService)
 {
     BlogService = blogService;
 }
Пример #57
0
 public BlogController(IBlogService blogService, ISessionContext sessionContext)
 {
     _blogService    = blogService;
     _sessionContext = sessionContext;
 }
Пример #58
0
 public HomeController(IAccountService _accountService, IProductService _productService, IImageService _imageService,
                       IManufactorService _manufactorService, ICategoryService _categoryService, IAnimeService _animeService,
                       IWishListService _wishListService, IProductTagService _productTagService, ITagService _tagService, IBlogService _blogService,
                       IMessageSendingService _messageSendingService, IWebsiteAttributeService _websiteAttributeService,
                       IFAQService _faqService)
 {
     this._accountService          = _accountService;
     this._productService          = _productService;
     this._imageService            = _imageService;
     this._manufactorService       = _manufactorService;
     this._categoryService         = _categoryService;
     this._animeService            = _animeService;
     this._wishListService         = _wishListService;
     this._blogService             = _blogService;
     this._tagService              = _tagService;
     this._productTagService       = _productTagService;
     this._messageSendingService   = _messageSendingService;
     this._websiteAttributeService = _websiteAttributeService;
     this._faqService              = _faqService;
 }
Пример #59
0
 public BlogsController(IBlogService blogService, IMapper mapper)
 {
     _blogService = blogService;
     _mapper      = mapper;
 }
Пример #60
0
 public HomeController(IBlogService blogService)
 {
     _blogService = blogService;
 }