示例#1
0
 public NewsItemPageView(string id)
     : base()
 {
     newsManager = Resolver.GetInstance<INewsManager>();
     commentsManager = Resolver.GetInstance<ICommentsManager>();
     NewsItem = Mapper.Map<NewsItemViewModel, NewsItem>(newsManager.GetById(id));
     Comments = Mapper.Map<CommentViewModel, Comment>(commentsManager.GetList(NewsItem.Id));
 }
示例#2
0
 public NewsItemPageView(string id)
     : base()
 {
     newsManager     = Resolver.GetInstance <INewsManager>();
     commentsManager = Resolver.GetInstance <ICommentsManager>();
     NewsItem        = Mapper.Map <NewsItemViewModel, NewsItem>(newsManager.GetById(id));
     Comments        = Mapper.Map <CommentViewModel, Comment>(commentsManager.GetList(NewsItem.Id));
 }
 /// <summary>
 /// Initializes a new instance of the <see cref="CommentsController"/> class
 /// </summary>
 /// <param name="log">Log</param>
 /// <param name="commentsManager">Comments manager</param>
 /// <param name="viewsManager">Views manager</param>
 public CommentsController(
     ILog log,
     ICommentsManager commentsManager,
     IViewsManager viewsManager)
 {
     this.log             = log;
     this.commentsManager = commentsManager;
     this.viewsManager    = viewsManager;
 }
 /// <summary>
 /// Initializes a new instance of the <see cref="TopicReportsController"/> class
 /// </summary>
 /// <param name="log">Log</param>
 /// <param name="reportsManager">Reports manager</param>
 /// <param name="topicsManager">Topics manager</param>
 /// <param name="commentsManager">Comments manager</param>
 /// <param name="repliesManager">Replies manager</param>
 /// <param name="usersManager">Users manager</param>
 /// <param name="handleGenerator">Handle generator</param>
 public TopicReportsController(
     ILog log,
     IReportsManager reportsManager,
     ITopicsManager topicsManager,
     ICommentsManager commentsManager,
     IRepliesManager repliesManager,
     IUsersManager usersManager,
     IHandleGenerator handleGenerator)
     : base(log, reportsManager, topicsManager, commentsManager, repliesManager, usersManager, handleGenerator)
 {
     this.log           = log;
     this.topicsManager = topicsManager;
 }
示例#5
0
 /// <summary>
 /// Initializes a new instance of the <see cref="CommentRepliesController"/> class
 /// </summary>
 /// <param name="log">Log</param>
 /// <param name="commentsManager">Comments manager</param>
 /// <param name="repliesManager">Replies manager</param>
 /// <param name="viewsManager">Views manager</param>
 /// <param name="handleGenerator">Handle generator</param>
 public CommentRepliesController(
     ILog log,
     ICommentsManager commentsManager,
     IRepliesManager repliesManager,
     IViewsManager viewsManager,
     IHandleGenerator handleGenerator)
 {
     this.log             = log;
     this.commentsManager = commentsManager;
     this.repliesManager  = repliesManager;
     this.viewsManager    = viewsManager;
     this.handleGenerator = handleGenerator;
 }
 /// <summary>
 /// Initializes a new instance of the <see cref="ReplyLikesController"/> class
 /// </summary>
 /// <param name="log">Log</param>
 /// <param name="likesManager">Likes manager</param>
 /// <param name="topicsManager">Topics manager</param>
 /// <param name="commentsManager">Comments manager</param>
 /// <param name="repliesManager">Replies manager</param>
 /// <param name="viewsManager">Views manager</param>
 /// <param name="handleGenerator">Handle generator</param>
 /// <param name="applicationMetrics">Application metrics logger</param>
 public ReplyLikesController(
     ILog log,
     ILikesManager likesManager,
     ITopicsManager topicsManager,
     ICommentsManager commentsManager,
     IRepliesManager repliesManager,
     IViewsManager viewsManager,
     IHandleGenerator handleGenerator,
     IApplicationMetrics applicationMetrics)
     : base(log, likesManager, topicsManager, commentsManager, repliesManager, viewsManager, handleGenerator, applicationMetrics)
 {
     this.log = log;
 }
示例#7
0
 /// <summary>
 /// Initializes a new instance of the <see cref="ReportsControllerBase"/> class
 /// </summary>
 /// <param name="log">Log</param>
 /// <param name="reportsManager">Reports manager</param>
 /// <param name="topicsManager">Topics manager</param>
 /// <param name="commentsManager">Comments manager</param>
 /// <param name="repliesManager">Replies manager</param>
 /// <param name="usersManager">Users manager</param>
 /// <param name="handleGenerator">Handle generator</param>
 public ReportsControllerBase(
     ILog log,
     IReportsManager reportsManager,
     ITopicsManager topicsManager,
     ICommentsManager commentsManager,
     IRepliesManager repliesManager,
     IUsersManager usersManager,
     IHandleGenerator handleGenerator)
 {
     this.log             = log;
     this.reportsManager  = reportsManager;
     this.handleGenerator = handleGenerator;
 }
示例#8
0
 public Api(IMapper mapper, ITagsCrudService tagsCrudService, IResourcesManager resourcesManager, ICollectionsCrudService collectionsCrudService, IOptionalFieldsManager optionalFieldsManager, IItemsManager itemsManager,
            ICollectionsManager collectionsManager, IItemsCrudService itemsCrudService, ILikesManager likesManager, ICommentsManager commentsManager)
 {
     this.mapper                 = mapper;
     this.resourcesManager       = resourcesManager;
     this.collectionsCrudService = collectionsCrudService;
     this.optionalFieldsManager  = optionalFieldsManager;
     this.itemsManager           = itemsManager;
     this.collectionsManager     = collectionsManager;
     this.tagsCrudService        = tagsCrudService;
     this.itemsCrudService       = itemsCrudService;
     this.likesManager           = likesManager;
     this.commentsManager        = commentsManager;
 }
示例#9
0
 /// <summary>
 /// Initializes a new instance of the <see cref="TopicCommentsController"/> class
 /// </summary>
 /// <param name="log">Log</param>
 /// <param name="topicsManager">Topics manager</param>
 /// <param name="commentsManager">Comments manager</param>
 /// <param name="viewsManager">Views manager</param>
 /// <param name="handleGenerator">Handle generator</param>
 /// <param name="applicationMetrics">Application metrics logger</param>
 public TopicCommentsController(
     ILog log,
     ITopicsManager topicsManager,
     ICommentsManager commentsManager,
     IViewsManager viewsManager,
     IHandleGenerator handleGenerator,
     IApplicationMetrics applicationMetrics)
 {
     this.log                = log;
     this.topicsManager      = topicsManager;
     this.commentsManager    = commentsManager;
     this.viewsManager       = viewsManager;
     this.handleGenerator    = handleGenerator;
     this.applicationMetrics = applicationMetrics;
 }
示例#10
0
 public CommentsController(
     IMaterialsManager materialsManager,
     CommentsAuthorization commentsAuthorization,
     OperationKeysContainer operationKeys,
     ICommentsManager commentsManager,
     IAuthorizationService authorizationService,
     ICommentsPresenter commentsPresenter,
     IServiceProvider serviceProvider) : base(serviceProvider)
 {
     OperationKeys = operationKeys;
     this.commentsAuthorization = commentsAuthorization;
     this.materialsManager      = materialsManager;
     this.commentsManager       = commentsManager;
     this.authorizationService  = authorizationService;
     this.commentsPresenter     = commentsPresenter;
 }
示例#11
0
 /// <summary>
 /// Initializes a new instance of the <see cref="LikesControllerBase"/> class
 /// </summary>
 /// <param name="log">Log</param>
 /// <param name="likesManager">Likes manager</param>
 /// <param name="topicsManager">Topics manager</param>
 /// <param name="commentsManager">Comments manager</param>
 /// <param name="repliesManager">Replies manager</param>
 /// <param name="viewsManager">Views manager</param>
 /// <param name="handleGenerator">Handle generator</param>
 /// <param name="applicationMetrics">Application metrics logger</param>
 public LikesControllerBase(
     ILog log,
     ILikesManager likesManager,
     ITopicsManager topicsManager,
     ICommentsManager commentsManager,
     IRepliesManager repliesManager,
     IViewsManager viewsManager,
     IHandleGenerator handleGenerator,
     IApplicationMetrics applicationMetrics)
 {
     this.log                = log;
     this.likesManager       = likesManager;
     this.topicsManager      = topicsManager;
     this.commentsManager    = commentsManager;
     this.repliesManager     = repliesManager;
     this.viewsManager       = viewsManager;
     this.handleGenerator    = handleGenerator;
     this.applicationMetrics = applicationMetrics;
 }
示例#12
0
 public CommentsController()
 {
     manager = Resolver.GetInstance <ICommentsManager>();
 }
 public CommentsController(ICommentsManager commentsManager,
                           ITokenManager tokenManager)
 {
     _commentsManager = commentsManager;
     _tokenManager    = tokenManager;
 }
示例#14
0
 public ArticleController(IArticleManager articleManager, ICommentsManager commentsManager, ITagsManager tagsManager)
 {
     this._articleManager  = articleManager;
     this._commentsManager = commentsManager;
     this._tagsManager     = tagsManager;
 }
		public AbusesController(ICommentsManager commentsManager, ICultureManager cultureManager)
		{
			_commentsManager = commentsManager;
			_cultureManager = cultureManager;
		}
示例#16
0
 public ItemHub(ILikesManager likesManager, ICommentsManager commentsManager, ISessionHelper sessionHelper) : base()
 {
     this.likesManager    = likesManager;
     this.commentsManager = commentsManager;
     this.sessionHelper   = sessionHelper;
 }
示例#17
0
 public CommentsController()
 {
     manager = Resolver.GetInstance<ICommentsManager>();
 }