public PollModule(TinyIoc.TinyIoCContainer container, IPollService pollService = null, ISessionProvider sessionProvider = null)
    {
      if (container == null) throw new ArgumentNullException("container");
      if (!(sessionProvider is DefaultSessionProvider)) _SessionProvider = sessionProvider;

      if (pollService == null)
      {
        container.Register<IPollService, PollService>().AsSingleton();
        pollService = container.Resolve<IPollService>();
      }
      _PollService = pollService as PollService;
      if (pollService == null) throw new ApplicationException("Support Nany.LongPoll.PollService implementation only");

      Get["/Poll/Register"] = x =>
      {
        var sp = _SessionProvider;
        if (sp == null) sp = new DefaultSessionProvider(Request);

        var response = Response.AsJson(_PollService.Register(Request.UserHostAddress, sp.SessionId));
        if (sp is DefaultSessionProvider)
        {
          response = response.WithCookie(DefaultSessionProvider.SessionIdCookieName, sp.SessionId);
        }

        return response;
      };
      Get["/Poll/Wait"] = x =>
      {
        string clientId = Request.Query.clientId;
        ulong seqCode = Request.Query.seqCode;

        return Response.AsText(JsonConvert.SerializeObject(_PollService.Wait(clientId, seqCode)), "application/json");
      };
    }
Exemple #2
0
 /// <summary>
 /// Constructor
 /// </summary>
 /// <param name="context"></param>
 /// <param name="settingsService"> </param>
 /// <param name="emailService"> </param>
 /// <param name="localizationService"> </param>
 /// <param name="activityService"> </param>
 /// <param name="privateMessageService"> </param>
 /// <param name="membershipUserPointsService"> </param>
 /// <param name="topicNotificationService"> </param>
 /// <param name="voteService"> </param>
 /// <param name="badgeService"> </param>
 /// <param name="categoryNotificationService"> </param>
 /// <param name="loggingService"></param>
 /// <param name="uploadedFileService"></param>
 /// <param name="postService"></param>
 /// <param name="pollVoteService"></param>
 /// <param name="pollAnswerService"></param>
 /// <param name="pollService"></param>
 /// <param name="topicService"></param>
 /// <param name="favouriteService"></param>
 /// <param name="categoryService"></param>
 public MembershipService(IMVCForumContext context, ISettingsService settingsService,
     IEmailService emailService, ILocalizationService localizationService, IActivityService activityService,
     IPrivateMessageService privateMessageService, IMembershipUserPointsService membershipUserPointsService,
     ITopicNotificationService topicNotificationService, IVoteService voteService, IBadgeService badgeService,
     ICategoryNotificationService categoryNotificationService, ILoggingService loggingService, IUploadedFileService uploadedFileService,
     IPostService postService, IPollVoteService pollVoteService, IPollAnswerService pollAnswerService,
     IPollService pollService, ITopicService topicService, IFavouriteService favouriteService, 
     ICategoryService categoryService, IPostEditService postEditService)
 {
     _settingsService = settingsService;
     _emailService = emailService;
     _localizationService = localizationService;
     _activityService = activityService;
     _privateMessageService = privateMessageService;
     _membershipUserPointsService = membershipUserPointsService;
     _topicNotificationService = topicNotificationService;
     _voteService = voteService;
     _badgeService = badgeService;
     _categoryNotificationService = categoryNotificationService;
     _loggingService = loggingService;
     _uploadedFileService = uploadedFileService;
     _postService = postService;
     _pollVoteService = pollVoteService;
     _pollAnswerService = pollAnswerService;
     _pollService = pollService;
     _topicService = topicService;
     _favouriteService = favouriteService;
     _categoryService = categoryService;
     _postEditService = postEditService;
     _context = context as MVCForumContext;
 }
		public OptionAdminController(IOrchardServices services, IPollService pollService) {
			_services = services;
			_pollService = pollService;
			_notifier = _services.Notifier;
			New = _services.New;
			T = NullLocalizer.Instance;
		}
Exemple #4
0
 public PollController(ILoggingService loggingService, IUnitOfWorkManager unitOfWorkManager, IMembershipService membershipService, 
     ILocalizationService localizationService, IRoleService roleService, ISettingsService settingsService, IPollService pollService, IPollVoteService pollVoteService, 
     IPollAnswerService pollAnswerService)
     : base(loggingService, unitOfWorkManager, membershipService, localizationService, roleService, settingsService)
 {
     _pollService = pollService;
     _pollAnswerService = pollAnswerService;
     _pollVoteService = pollVoteService;
 }
Exemple #5
0
 public PollController(ILocalizationService localizationService,
     IWorkContext workContext, IPollService pollService,
     IWebHelper webHelper)
 {
     this._localizationService = localizationService;
     this._workContext = workContext;
     this._pollService = pollService;
     this._webHelper = webHelper;
 }
Exemple #6
0
 public PollController(ILocalizationService localizationService,
                       IWorkContext workContext, IPollService pollService,
                       IWebHelper webHelper, ICacheManager cacheManager)
 {
     this._localizationService = localizationService;
     this._workContext         = workContext;
     this._pollService         = pollService;
     this._webHelper           = webHelper;
     this._cacheManager        = cacheManager;
 }
 public PollController(ILocalizationService localizationService,
     IWorkContext workContext,
     IPollService pollService,
     ICacheManager cacheManager)
 {
     this._localizationService = localizationService;
     this._workContext = workContext;
     this._pollService = pollService;
     this._cacheManager = cacheManager;
 }
 public PollController(IPollService pollService, ILanguageService languageService,
     IDateTimeHelper dateTimeHelper, ILocalizationService localizationService,
     IPermissionService permissionService)
 {
     this._pollService = pollService;
     this._languageService = languageService;
     this._dateTimeHelper = dateTimeHelper;
     this._localizationService = localizationService;
     this._permissionService = permissionService;
 }
Exemple #9
0
 public PollController(IPollViewModelService pollViewModelService,
                       ILocalizationService localizationService,
                       IWorkContext workContext,
                       IPollService pollService)
 {
     _pollViewModelService = pollViewModelService;
     _localizationService  = localizationService;
     _workContext          = workContext;
     _pollService          = pollService;
 }
 public PollModelFactory(IPollService pollService,
                         IStaticCacheManager staticCacheManager,
                         IStoreContext storeContext,
                         IWorkContext workContext)
 {
     _pollService        = pollService;
     _staticCacheManager = staticCacheManager;
     _storeContext       = storeContext;
     _workContext        = workContext;
 }
Exemple #11
0
 public InteractionController()
 {
     _administratorService  = new AdministratorServiceImpl(context);
     _residentService       = new ResidentServiceImpl(context);
     _userService           = new UserServiceImpl(context);
     _newsService           = new NewsServiceImpl(context);
     _optionResidentService = new OptionResidentServiceImpl(context);
     _optionService         = new OptionServiceImpl(context);
     _pollService           = new PollServiceImpl(context);
 }
Exemple #12
0
 public PollController(IPollModelFactory pollModelFactory,
                       ILocalizationService localizationService,
                       IWorkContext workContext,
                       IPollService pollService)
 {
     this._pollModelFactory    = pollModelFactory;
     this._localizationService = localizationService;
     this._workContext         = workContext;
     this._pollService         = pollService;
 }
Exemple #13
0
 public PollModelFactory(IPollService pollService,
                         IStaticCacheManager cacheManager,
                         IStoreContext storeContext,
                         IWorkContext workContext)
 {
     this._pollService  = pollService;
     this._cacheManager = cacheManager;
     this._storeContext = storeContext;
     this._workContext  = workContext;
 }
Exemple #14
0
 public PollApiViewModelService(ITenantProvider tenantProvider, IPollService pollService, IMapper mapper,
                                IVoteService voteService, IUserService userService, ISettingService settingService)
 {
     _tenantProvider = tenantProvider;
     _pollService    = pollService;
     _mapper         = mapper;
     _voteService    = voteService;
     _userService    = userService;
     _settingService = settingService;
 }
Exemple #15
0
 public PollController(IPollService pollService, ILanguageService languageService,
                       IDateTimeHelper dateTimeHelper, ILocalizationService localizationService,
                       IPermissionService permissionService)
 {
     _pollService         = pollService;
     _languageService     = languageService;
     _dateTimeHelper      = dateTimeHelper;
     _localizationService = localizationService;
     _permissionService   = permissionService;
 }
 public PollController(
     IOrchardServices services, 
     IShapeFactory shapeFactory,
     IPollService pollService) {
     _pollService = pollService;
     Services = services;
     Logger = NullLogger.Instance;
     T = NullLocalizer.Instance;
     Shape = shapeFactory;
 }
Exemple #17
0
 public PollController(IPollWebService pollWebService,
                       ILocalizationService localizationService,
                       IWorkContext workContext,
                       IPollService pollService)
 {
     this._pollWebService      = pollWebService;
     this._localizationService = localizationService;
     this._workContext         = workContext;
     this._pollService         = pollService;
 }
 public PollViewModelService(IPollService pollService, IWorkContext workContext, IStoreContext storeContext, ICacheManager cacheManager, IAclService aclService,
                             IServiceProvider serviceProvider)
 {
     this._pollService     = pollService;
     this._workContext     = workContext;
     this._storeContext    = storeContext;
     this._cacheManager    = cacheManager;
     this._aclService      = aclService;
     this._serviceProvider = serviceProvider;
 }
 public PollController(IPollService pollService, ILanguageService languageService,
                       ILocalizationService localizationService,
                       IStoreService storeService,
                       ICustomerService customerService)
 {
     this._pollService         = pollService;
     this._languageService     = languageService;
     this._localizationService = localizationService;
     this._storeService        = storeService;
     this._customerService     = customerService;
 }
 public UserController(IUserService userService, IMapper mapper, IProfileHelthHelper profileHelthHelper, IPollService pollService,
                       INotificationService notificationService, IUserStatisticsService userStatisticsService, IWebHostEnvironment env)
 {
     _userService           = userService ?? throw new ArgumentNullException(nameof(userService));
     _mapper                = mapper ?? throw new ArgumentNullException(nameof(mapper));
     _profileHelthHelper    = profileHelthHelper ?? throw new ArgumentNullException(nameof(profileHelthHelper));
     _pollService           = pollService ?? throw new ArgumentNullException(nameof(pollService));
     _notificationService   = notificationService ?? throw new ArgumentNullException(nameof(notificationService));
     _userStatisticsService = userStatisticsService ?? throw new ArgumentNullException(nameof(userStatisticsService));
     _env = env ?? throw new ArgumentNullException(nameof(env));
 }
Exemple #21
0
 public PollController(ILoggingService loggingService, IMembershipService membershipService,
                       ILocalizationService localizationService, IRoleService roleService, ISettingsService settingsService,
                       IPollService pollService, IPollVoteService pollVoteService, IPollAnswerService pollAnswerService,
                       ICacheService cacheService, IMvcForumContext context)
     : base(loggingService, membershipService, localizationService, roleService,
            settingsService, cacheService, context)
 {
     _pollService       = pollService;
     _pollAnswerService = pollAnswerService;
     _pollVoteService   = pollVoteService;
 }
Exemple #22
0
 public GetHomePagePollsHandler(IWorkContext workContext,
                                IStoreContext storeContext,
                                ICacheBase cacheManager,
                                IPollService pollService
                                )
 {
     _workContext  = workContext;
     _storeContext = storeContext;
     _cacheBase    = cacheManager;
     _pollService  = pollService;
 }
Exemple #23
0
 public SongService(
     IRepository <SongPartRecord> songRepository,
     IRepository <PollChoiceRecord> choiceRepository,
     IPollService pollService,
     IOrchardServices orchardServices)
 {
     _songRepository   = songRepository;
     _choiceRepository = choiceRepository;
     _pollService      = pollService;
     _orchardServices  = orchardServices;
 }
Exemple #24
0
        public PollController(ILoggingService loggingService, IUnitOfWorkManager unitOfWorkManager, IMembershipService membershipService, 
            ILocalizationService localizationService, IRoleService roleService, ISettingsService settingsService, IPollService pollService, IPollVoteService pollVoteService, 
            IPollAnswerService pollAnswerService)
            : base(loggingService, unitOfWorkManager, membershipService, localizationService, roleService, settingsService)
        {
            _pollService = pollService;
            _pollAnswerService = pollAnswerService;
            _pollVoteService = pollVoteService;

            LoggedOnUser = UserIsAuthenticated ? MembershipService.GetUser(Username) : null;
        }
 public PollController(IPollService pollService, ILanguageService languageService,
                       IDateTimeHelper dateTimeHelper, ILocalizationService localizationService,
                       IPermissionService permissionService, AdminAreaSettings adminAreaSettings)
 {
     this._pollService         = pollService;
     this._languageService     = languageService;
     this._dateTimeHelper      = dateTimeHelper;
     this._localizationService = localizationService;
     this._permissionService   = permissionService;
     this._adminAreaSettings   = adminAreaSettings;
 }
 public ApiMultipleChoicePollController(IPollService pollService, IPollApiViewModelService pollViewModelService,
                                        IMapper mapper, IVoteService voteService, IStringLocalizer <ApiMultipleChoicePollController> localizer,
                                        IUserService userService)
 {
     _pollService          = pollService;
     _pollViewModelService = pollViewModelService;
     _mapper      = mapper;
     _voteService = voteService;
     _localizer   = localizer;
     _userService = userService;
 }
 public ApiPolicyController(IPolicyService policyService, IPollService pollService,
                            IStringLocalizer <ApiPolicyController> localizer, IPollApiViewModelService pollViewModelService,
                            ITenantProvider tenantProvider, IMapper mapper)
 {
     _policyService        = policyService;
     _pollService          = pollService;
     _localizer            = localizer;
     _pollViewModelService = pollViewModelService;
     _tenantProvider       = tenantProvider;
     _mapper = mapper;
 }
        public PollController(IPollService pollService, ILanguageService languageService,
            IDateTimeHelper dateTimeHelper, ILocalizationService localizationService,
            IPermissionService permissionService, AdminAreaSettings adminAreaSettings)
        {
            this._pollService = pollService;
            this._languageService = languageService;
            this._dateTimeHelper = dateTimeHelper;
            this._localizationService = localizationService;
            this._permissionService = permissionService;
            this._adminAreaSettings = adminAreaSettings;
		}
Exemple #29
0
        public PollController(ILoggingService loggingService, IUnitOfWorkManager unitOfWorkManager, IMembershipService membershipService,
                              ILocalizationService localizationService, IRoleService roleService, ISettingsService settingsService, IPollService pollService, IPollVoteService pollVoteService,
                              IPollAnswerService pollAnswerService)
            : base(loggingService, unitOfWorkManager, membershipService, localizationService, roleService, settingsService)
        {
            _pollService       = pollService;
            _pollAnswerService = pollAnswerService;
            _pollVoteService   = pollVoteService;


            LoggedOnUser = UserIsAuthenticated ? MembershipService.GetUser(Username) : null;
        }
Exemple #30
0
 public PollsController(IPollRepository pollRepository,
                        IVoteRepository voteRepository,
                        IMapper mapper,
                        IPollService pollService,
                        ITinyMessengerHub messengerHub)
 {
     _pollService    = pollService ?? throw new ArgumentNullException(nameof(pollService));
     _mapper         = mapper ?? throw new ArgumentNullException(nameof(mapper));
     _pollRepository = pollRepository ?? throw new ArgumentNullException(nameof(pollRepository));
     _voteRepository = voteRepository ?? throw new ArgumentNullException(nameof(voteRepository));
     _messengerHub   = messengerHub ?? throw new ArgumentNullException(nameof(messengerHub));
 }
Exemple #31
0
 public PollJobService(IPollService pollService, IUserService userService, IVoteService voteService,
                       ISettingService settingService, IPollRepository pollRepository, ITenantService tenantService,
                       IPolicyService policyService)
 {
     _pollService    = pollService;
     _userService    = userService;
     _voteService    = voteService;
     _settingService = settingService;
     _pollRepository = pollRepository;
     _tenantService  = tenantService;
     _policyService  = policyService;
 }
Exemple #32
0
 public YesNoAnswersController(IYesNoAnswerService yesNoAnswerService,
                               IPollService pollService,
                               IUserService userService,
                               IUserSurveysService userSurveysService,
                               IYesNoQuestionService yesNoQuestionService)
 {
     this.yesNoAnswerService   = yesNoAnswerService;
     this.pollService          = pollService;
     this.userSurveysService   = userSurveysService;
     this.yesNoQuestionService = yesNoQuestionService;
     this.userService          = userService;
 }
        public async Task <VotePayload> Vote(
            VoteInput vote,
            [Service] IPollService pollService,
            [Service] IPollRepository pollRepository,
            [Service] PollContext pollContext,
            [Service] IHttpContextAccessor httpContextAccessor)
        {
            int    userId = httpContextAccessor.UserId();
            Result result = await pollService.Answer(pollContext, pollRepository, vote.PollId, userId, vote.ProposalId);

            return(result.ToGraphQL(() => new VotePayload(), (p, e) => p.Errors = e));
        }
        public PollController(ILocalizationService localizationService,
            IWorkContext workContext, IPollService pollService,
            IWebHelper webHelper, ICacheManager cacheManager,
			IStoreContext storeContext)
        {
            this._localizationService = localizationService;
            this._workContext = workContext;
            this._pollService = pollService;
            this._webHelper = webHelper;
            this._cacheManager = cacheManager;
			this._storeContext = storeContext;
        }
Exemple #35
0
 public PollController(ILocalizationService localizationService,
                       IPollModelFactory pollModelFactory,
                       IPollService pollService,
                       IStoreMappingService storeMappingService,
                       IWorkContext workContext)
 {
     this._localizationService = localizationService;
     this._pollModelFactory    = pollModelFactory;
     this._pollService         = pollService;
     this._storeMappingService = storeMappingService;
     this._workContext         = workContext;
 }
 public PollModelFactory(IBaseAdminModelFactory baseAdminModelFactory,
                         IDateTimeHelper dateTimeHelper,
                         ILanguageService languageService,
                         IPollService pollService,
                         IStoreMappingSupportedModelFactory storeMappingSupportedModelFactory)
 {
     this._baseAdminModelFactory             = baseAdminModelFactory;
     this._dateTimeHelper                    = dateTimeHelper;
     this._languageService                   = languageService;
     this._pollService                       = pollService;
     this._storeMappingSupportedModelFactory = storeMappingSupportedModelFactory;
 }
 public PollController(
     IPollService pollService,
     ICountryValidationService countryValidationService,
     IPollResultService pollResultService,
     IPollItemService pollItemService,
     IHubContext <VoteHub> rulesHubContext)
 {
     _pollService = pollService;
     _countryValidationService = countryValidationService;
     _pollResultService        = pollResultService;
     _pollItemService          = pollItemService;
     _rulesHubContext          = rulesHubContext;
 }
 public ApiPollController(IPollService pollService, IMapper mapper, IUserService userService,
                          IPollApiViewModelService pollViewModelService, IStringLocalizer <ApiPollController> localizer,
                          IVoteService voteService, IGenericService genericService, ITenantProvider tenantProvider)
 {
     _pollService          = pollService;
     _mapper               = mapper;
     _userService          = userService;
     _pollViewModelService = pollViewModelService;
     _localizer            = localizer;
     _voteService          = voteService;
     _genericService       = genericService;
     _tenantProvider       = tenantProvider;
 }
 public PollController(IPollService pollService, ILanguageService languageService,
                       IDateTimeHelper dateTimeHelper, ILocalizationService localizationService,
                       IPermissionService permissionService, IStoreService storeService,
                       ICustomerService customerService)
 {
     this._pollService         = pollService;
     this._languageService     = languageService;
     this._dateTimeHelper      = dateTimeHelper;
     this._localizationService = localizationService;
     this._permissionService   = permissionService;
     this._storeService        = storeService;
     this._customerService     = customerService;
 }
Exemple #40
0
 public PollController(IPollService pollService, ILanguageService languageService,
                       ILocalizationService localizationService,
                       IStoreService storeService,
                       ICustomerService customerService,
                       IDateTimeHelper dateTimeHelper)
 {
     _pollService         = pollService;
     _languageService     = languageService;
     _localizationService = localizationService;
     _storeService        = storeService;
     _customerService     = customerService;
     _dateTimeHelper      = dateTimeHelper;
 }
Exemple #41
0
 public PollController(
     IWorkContext workContext,
     IPollService pollService,
     IWebHelper webHelper,
     ICacheManager cacheManager,
     IStoreContext storeContext)
 {
     this._workContext  = workContext;
     this._pollService  = pollService;
     this._webHelper    = webHelper;
     this._cacheManager = cacheManager;
     this._storeContext = storeContext;
 }
Exemple #42
0
 public TopicService(IMVCForumContext context, IMembershipUserPointsService membershipUserPointsService,
     ISettingsService settingsService, ITopicNotificationService topicNotificationService,
     IFavouriteService favouriteService,
     IPostService postService, IRoleService roleService, IPollService pollService, IPollAnswerService pollAnswerService, ICacheService cacheService)
 {
     _membershipUserPointsService = membershipUserPointsService;
     _settingsService = settingsService;
     _topicNotificationService = topicNotificationService;
     _favouriteService = favouriteService;
     _postService = postService;
     _roleService = roleService;
     _pollService = pollService;
     _pollAnswerService = pollAnswerService;
     _cacheService = cacheService;
     _context = context as MVCForumContext;
 }
        public AdminController(
            IDateLocalizationServices dateLocalizationServices,
            IOrchardServices services,
            IPollService pollService,
            ISiteService siteService,
            IShapeFactory shapeFactory)
        {
            Services = services;
            _dateLocalizationServices = dateLocalizationServices;
            _pollService = pollService;
            _siteService = siteService;

            Shape = shapeFactory;
            T = NullLocalizer.Instance;
            Logger = NullLogger.Instance;
        }
Exemple #44
0
 /// <summary>
 /// Constructor
 /// </summary>
 /// <param name="unitOfWorkManager"> </param>
 /// <param name="membershipService"></param>
 /// <param name="localizationService"> </param>
 /// <param name="roleService"> </param>
 /// <param name="settingsService"> </param>
 /// <param name="loggingService"> </param>
 /// <param name="postService"> </param>
 /// <param name="topicService"> </param>
 /// <param name="membershipUserPointsService"> </param>
 /// <param name="activityService"> </param>
 /// <param name="pollService"> </param>
 /// <param name="pollVoteService"> </param>
 /// <param name="pollAnswerService"> </param>
 /// <param name="uploadedFileService"></param>
 public AccountController(ILoggingService loggingService,
     IUnitOfWorkManager unitOfWorkManager,
     IMembershipService membershipService,
     ILocalizationService localizationService,
     IRoleService roleService,
     ISettingsService settingsService, IPostService postService, ITopicService topicService, IMembershipUserPointsService membershipUserPointsService, 
     IActivityService activityService, IPollService pollService, IPollVoteService pollVoteService, IPollAnswerService pollAnswerService, IUploadedFileService uploadedFileService)
     : base(loggingService, unitOfWorkManager, membershipService, localizationService, settingsService)
 {
     _activityService = activityService;
     _roleService = roleService;
     _postService = postService;
     _topicService = topicService;
     _membershipUserPointsService = membershipUserPointsService;
     _pollService = pollService;
     _pollVoteService = pollVoteService;
     _pollAnswerService = pollAnswerService;
     _uploadedFileService = uploadedFileService;
 }
Exemple #45
0
 public PostController(ILoggingService loggingService, IUnitOfWorkManager unitOfWorkManager, IMembershipService membershipService,
     ILocalizationService localizationService, IRoleService roleService, ITopicService topicService, IPostService postService,
     ISettingsService settingsService, ICategoryService categoryService, ITopicTagService topicTagService,
     ITopicNotificationService topicNotificationService, IEmailService emailService, IReportService reportService, IPollAnswerService pollAnswerService,
     IPollService pollService, IBannedWordService bannedWordService, IMembershipUserPointsService membershipUserPointsService, IVoteService voteService)
     : base(loggingService, unitOfWorkManager, membershipService, localizationService, roleService, settingsService)
 {
     _topicService = topicService;
     _postService = postService;
     _categoryService = categoryService;
     _topicTagService = topicTagService;
     _topicNotificationService = topicNotificationService;
     _emailService = emailService;
     _reportService = reportService;
     _pollAnswerService = pollAnswerService;
     _pollService = pollService;
     _bannedWordService = bannedWordService;
     _membershipUserPointsService = membershipUserPointsService;
     _voteService = voteService;
 }
Exemple #46
0
        public PostController(ILoggingService loggingService, IUnitOfWorkManager unitOfWorkManager, IMembershipService membershipService, 
            ILocalizationService localizationService, IRoleService roleService, ITopicService topicService, IPostService postService, 
            ISettingsService settingsService, ICategoryService categoryService, ITopicTagService topicTagService, 
            ITopicNotificationService topicNotificationService, IEmailService emailService, IReportService reportService, ILuceneService luceneService, IPollAnswerService pollAnswerService, 
            IPollService pollService, IBannedWordService bannedWordService)
            : base(loggingService, unitOfWorkManager, membershipService, localizationService, roleService, settingsService)
        {
            _topicService = topicService;
            _postService = postService;
            _categoryService = categoryService;
            _topicTagService = topicTagService;
            _topicNotificationService = topicNotificationService;
            _emailService = emailService;
            _reportService = reportService;
            _luceneService = luceneService;
            _pollAnswerService = pollAnswerService;
            _pollService = pollService;
            _bannedWordService = bannedWordService;

            LoggedOnUser = UserIsAuthenticated ? MembershipService.GetUser(Username) : null;
            UsersRole = LoggedOnUser == null ? RoleService.GetRole(AppConstants.GuestRoleName) : LoggedOnUser.Roles.FirstOrDefault();
        }
Exemple #47
0
 public TopicController(ILoggingService loggingService, IUnitOfWorkManager unitOfWorkManager, IMembershipService membershipService, IRoleService roleService, ITopicService topicService, IPostService postService,
     ICategoryService categoryService, ILocalizationService localizationService, ISettingsService settingsService, ITopicTagService topicTagService, IMembershipUserPointsService membershipUserPointsService,
     ICategoryNotificationService categoryNotificationService, IEmailService emailService, ITopicNotificationService topicNotificationService, IPollService pollService,
     IPollAnswerService pollAnswerService, IBannedWordService bannedWordService, IVoteService voteService, IFavouriteService favouriteService, IUploadedFileService uploadedFileService, ICacheService cacheService, ITagNotificationService tagNotificationService)
     : base(loggingService, unitOfWorkManager, membershipService, localizationService, roleService, settingsService)
 {
     _topicService = topicService;
     _postService = postService;
     _categoryService = categoryService;
     _topicTagService = topicTagService;
     _membershipUserPointsService = membershipUserPointsService;
     _categoryNotificationService = categoryNotificationService;
     _emailService = emailService;
     _topicNotificationService = topicNotificationService;
     _pollService = pollService;
     _pollAnswerService = pollAnswerService;
     _bannedWordService = bannedWordService;
     _voteService = voteService;
     _favouriteService = favouriteService;
     _uploadedFileService = uploadedFileService;
     _cacheService = cacheService;
     _tagNotificationService = tagNotificationService;
 }
        public TopicController(ILoggingService loggingService, IUnitOfWorkManager unitOfWorkManager, IMembershipService membershipService, IRoleService roleService, ITopicService topicService, IPostService postService,
            ICategoryService categoryService, ILocalizationService localizationService, ISettingsService settingsService, ITopicTagService topicTagService, IMembershipUserPointsService membershipUserPointsService,
            ICategoryNotificationService categoryNotificationService, IEmailService emailService, ITopicNotificationService topicNotificationService, IPollService pollService,
            IPollAnswerService pollAnswerService, IBannedWordService bannedWordService, IVoteService voteService, IFavouriteService favouriteService, IUploadedFileService uploadedFileService)
            : base(loggingService, unitOfWorkManager, membershipService, localizationService, roleService, settingsService)
        {
            _topicService = topicService;
            _postService = postService;
            _categoryService = categoryService;
            _topicTagService = topicTagService;
            _membershipUserPointsService = membershipUserPointsService;
            _categoryNotificationService = categoryNotificationService;
            _emailService = emailService;
            _topicNotificationService = topicNotificationService;
            _pollService = pollService;
            _pollAnswerService = pollAnswerService;
            _bannedWordService = bannedWordService;
            _voteService = voteService;
            _favouriteService = favouriteService;
            _uploadedFileService = uploadedFileService;

            LoggedOnUser = UserIsAuthenticated ? MembershipService.GetUser(Username) : null;
            UsersRole = LoggedOnUser == null ? RoleService.GetRole(AppConstants.GuestRoleName) : LoggedOnUser.Roles.FirstOrDefault();
        }
 public MasterController()
 {
     ImageService = new ImageService();
     PollService = new PollService();
 }
		public PollController(IPollService pollService, INotifier notifier) {
			_pollService = pollService;
			_notifier = notifier;
			T = NullLocalizer.Instance;
		}
 public PollCreationController(IPollService pollService)
 {
     this.pollService = pollService;
 }
Exemple #52
0
		public PollHandler(IRepository<PollPartRecord> repository, IPollService pollService) {
			_pollService = pollService;
			Filters.Add(StorageFilter.For(repository));
			OnActivated<PollPart>(OnPollActivated);
		}
 public PollResultsController(IPollService pollService)
 {
     this.pollService = pollService;
 }
 public PollAnswerController(IPollService pollService)
 {
     this.pollService = pollService;
 }