public ArticleController(IArticleManager articleManager, ICommentManager commentManager, IUserManager userManager, ILogger.ILogger logger)
 {
     this.articleManager = articleManager;
     this.commentManager = commentManager;
     this.userManager = userManager;
     this.logger = logger;
 }
 public UserController(IUserManager userManager, IRoleManager roleManager, IArticleManager articleManager, ILogger.ILogger logger, ICommentManager comManager)
 {
     this.userManager = userManager;
     this.roleManager = roleManager;
     this.articleManager = articleManager;
     this.logger = logger;
     this.comManager = comManager;
 }
Esempio n. 3
0
        public GetNewProductsTask(
			ITaskSettings settings,
			ILastCallsRepository lastCallsRepository, 
			IPimQueryService pimQueryService,
			IPimCommandService pimCommandService,
			IArticleManager articleManager, 
			IMapper mapper)
        {
            _settings = settings;
            _lastCallsRepository = lastCallsRepository;
            _pimQueryService = pimQueryService;
            _pimCommandService = pimCommandService;
            _articleManager = articleManager;
            _mapper = mapper;
        }
Esempio n. 4
0
        public void Initilise()
        {
            _author = new Author
            {
                Id = 1,
                Name = "Fake Author 1"
            };

            _publisher = new User
            {
                Id = 1,
                Username = "FakePublisher1",
                Name = "Fake Publisher 1",
                Password = "password",
                Role = Role.Publisher
            };

            _employee = new User
            {
                Id = 1,
                Username = "FakeEmployee1",
                Name = "Fake Employee 1",
                Password = "password",
                Role = Role.Employee,
                Likes = 10
            };

            var articles = new List<Article>
            {
                new Article { Id = 1, Title = "News Article 1", Author = _author, Body = "This is a sample body for News Article 1", ArticleType = ArticleType.News, PublishDate = DateTime.Now, Likes = 2},
                new Article { Id = 2, Title = "News Article 2", Author = _author, Body = "This is a sample body for News Article 2", ArticleType = ArticleType.News, PublishDate = DateTime.Now , Likes = 48},
                new Article { Id = 3, Title = "Technology Article 1", Author = _author, Body = "This is a sample body for Technology Article 1", ArticleType = ArticleType.Technology, PublishDate = DateTime.Now , Likes = 0}
            };
            IArticleRepository articleRepository = new FakeArticleRepository(articles, new List<Author>() { _author });
            _articleManager = new ArticleManager(articleRepository);
        }
 public ArticleController(IArticleManager articleManager, IPlaceManager placeManager)
 {
     _articleManager = articleManager;
     _placeManager = placeManager;
 }
Esempio n. 6
0
 public ArticleController(IArticleManager articleManager)
 {
     _articleManager = articleManager;
 }
 public ReportController(IArticleManager articleManager, IUserManager userManager, ILogger.ILogger logger)
 {
     this.userManager = userManager;
     this.articleManager = articleManager;
     this.logger = logger;
 }