//public DataManipulationService(IServiceProvider serviceProvider, AddPostCommentServerAction addCommentServerAction, LikePostCommentServerAction likePostCommentServerAction, LikePostServerAction likePostServerAction, AddPostServerAction addPostServerAction, ProfileRepository profileRepository, ITimeService timeService, IEmailService emailService)
        //{
        //    _serviceProvider = serviceProvider;
        //    _addPostCommentServerAction = addCommentServerAction;
        //    _likePostCommentServerAction = likePostCommentServerAction;
        //    _likePostServerAction = likePostServerAction;
        //    _addPostServerAction = addPostServerAction;
        //    _profileRepository = profileRepository;
        //    _timeService = timeService;
        //    _emailService = emailService;
        //}

        public DataManipulationService(UniwikiContext uniwikiContext, IHashService hashService, IServiceProvider serviceProvider, StringStandardizationService stringStandardizationService)
        {
            _uniwikiContext  = uniwikiContext;
            _hashService     = hashService;
            _serviceProvider = serviceProvider;
            _stringStandardizationService = stringStandardizationService;
        }
Exemple #2
0
 public ChangePasswordServerAction(IServiceProvider serviceProvider, ProfileRepository profileRepository, TextService textService, IHashService hashService, UniwikiContext uniwikiContext) : base(serviceProvider)
 {
     _profileRepository = profileRepository;
     _textService       = textService;
     _hashService       = hashService;
     _uniwikiContext    = uniwikiContext;
 }
Exemple #3
0
 public UnlikePostServerAction(IServiceProvider serviceProvider, ProfileRepository profileRepository, PostRepository postRepository, PostLikeRepository postLikeRepository, UniwikiContext uniwikiContext) : base(serviceProvider)
 {
     _profileRepository  = profileRepository;
     _postRepository     = postRepository;
     _postLikeRepository = postLikeRepository;
     _uniwikiContext     = uniwikiContext;
 }
Exemple #4
0
 public RemovePostServerAction(IServiceProvider serviceProvider, PostRepository postRepository, ProfileRepository profileRepository, TextService textService, UniwikiContext uniwikiContext) : base(serviceProvider)
 {
     _postRepository    = postRepository;
     _profileRepository = profileRepository;
     _textService       = textService;
     _uniwikiContext    = uniwikiContext;
 }
Exemple #5
0
 public ConfirmEmailServerAction(IServiceProvider serviceProvider, EmailConfirmationSecretRepository emailConfirmationSecretRepository, ILoginService loginService, TextService textService, UniwikiContext uniwikiContext) : base(serviceProvider)
 {
     _emailConfirmationSecretRepository = emailConfirmationSecretRepository;
     _loginService   = loginService;
     _textService    = textService;
     _uniwikiContext = uniwikiContext;
 }
Exemple #6
0
 public ResendConfirmationEmailServerAction(IServiceProvider serviceProvider, ProfileRepository profileRepository, IInputValidationService inputValidationService, TextService textService, EmailConfirmationSenderService emailConfirmationSenderService, UniwikiContext uniwikiContext) : base(serviceProvider)
 {
     _profileRepository              = profileRepository;
     _inputValidationService         = inputValidationService;
     _textService                    = textService;
     _emailConfirmationSenderService = emailConfirmationSenderService;
     _uniwikiContext                 = uniwikiContext;
 }
 public LikePostCommentServerAction(IServiceProvider serviceProvider, ProfileRepository profileRepository, PostCommentRepository postCommentRepository, ITimeService timeService, PostCommentLikeRepository postCommentLikeRepository, TextService textService, UniwikiContext uniwikiContext) : base(serviceProvider)
 {
     _profileRepository         = profileRepository;
     _postCommentRepository     = postCommentRepository;
     _timeService               = timeService;
     _postCommentLikeRepository = postCommentLikeRepository;
     _textService               = textService;
     _uniwikiContext            = uniwikiContext;
 }
Exemple #8
0
 public CreateNewPasswordServerAction(IServiceProvider serviceProvider, NewPasswordSecretRepository newPasswordSecretRepository, ProfileRepository profileRepository, ITimeService timeService, TextService textService, IHashService hashService, UniwikiContext uniwikiContext) : base(serviceProvider)
 {
     _newPasswordSecretRepository = newPasswordSecretRepository;
     _profileRepository           = profileRepository;
     _timeService    = timeService;
     _textService    = textService;
     _hashService    = hashService;
     _uniwikiContext = uniwikiContext;
 }
 public GetCourseServerAction(IServiceProvider serviceProvider, CourseVisitRepository courseVisitRepository, ITimeService timeService, UniwikiContext uniwikiContext, TextService textService, UniwikiConfiguration uniwikiConfiguration, FetchPostsService fetchPostsService) : base(serviceProvider)
 {
     _courseVisitRepository = courseVisitRepository;
     _timeService           = timeService;
     _uniwikiContext        = uniwikiContext;
     _textService           = textService;
     _uniwikiConfiguration  = uniwikiConfiguration;
     _fetchPostsService     = fetchPostsService;
 }
Exemple #10
0
 public AddCourseServerAction(IServiceProvider serviceProvider, CourseRepository courseRepository, StudyGroupRepository studyGroupRepository, ProfileRepository profileRepository, StringStandardizationService stringStandardizationService, TextService textService, UniwikiContext uniwikiContext) : base(serviceProvider)
 {
     _courseRepository             = courseRepository;
     _studyGroupRepository         = studyGroupRepository;
     _profileRepository            = profileRepository;
     _stringStandardizationService = stringStandardizationService;
     _textService    = textService;
     _uniwikiContext = uniwikiContext;
 }
Exemple #11
0
 public GetSearchResultsServerAction(IServiceProvider serviceProvider, StudyGroupRepository studyGroupRepository, CourseRepository courseRepository, StringStandardizationService stringStandardizationService, CourseVisitRepository courseVisitRepository, ILogger <GetSearchResultsServerAction> logger, UniwikiContext uniwikiContext) : base(serviceProvider)
 {
     _studyGroupRepository         = studyGroupRepository;
     _courseRepository             = courseRepository;
     _stringStandardizationService = stringStandardizationService;
     _courseVisitRepository        = courseVisitRepository;
     _logger         = logger;
     _uniwikiContext = uniwikiContext;
 }
        public IQueryable <ProfileModel> EditHomeFaculty(Guid profileId, Guid?facultyId)
        {
            var profile = UniwikiContext.Profiles.Single(p => p.Id == profileId);

            profile.SetHomeFaculty(facultyId);

            UniwikiContext.SaveChanges();

            return(FindById(profileId));
        }
 public RestorePasswordServerAction(IServiceProvider serviceProvider, IEmailService emailService, ProfileRepository profileRepository, NewPasswordSecretRepository newPasswordSecretRepository, ITimeService timeService, TextService textService, UniwikiContext uniwikiContext)
     : base(serviceProvider)
 {
     _emailService                = emailService;
     _profileRepository           = profileRepository;
     _newPasswordSecretRepository = newPasswordSecretRepository;
     _timeService    = timeService;
     _textService    = textService;
     _uniwikiContext = uniwikiContext;
 }
 public EditPostServerAction(IServiceProvider serviceProvider, PostRepository postRepository, TextService textService, PostFileRepository postFileRepository, ProfileRepository profileRepository, ILogger <EditPostServerAction> logger, PostFileService postFileService, UniwikiContext uniwikiContext) : base(serviceProvider)
 {
     _postRepository     = postRepository;
     _textService        = textService;
     _postFileRepository = postFileRepository;
     _profileRepository  = profileRepository;
     _logger             = logger;
     _postFileService    = postFileService;
     _uniwikiContext     = uniwikiContext;
 }
 public LoginServerAction(IServiceProvider serviceProvider, TextService textService, CourseVisitRepository courseVisitRepository, CourseRepository courseRepository, ITimeService timeService, ILoginService loginService, RecentCoursesService recentCoursesService, UniwikiContext uniwikiContext) : base(serviceProvider)
 {
     _textService           = textService;
     _courseVisitRepository = courseVisitRepository;
     _courseRepository      = courseRepository;
     _timeService           = timeService;
     _loginService          = loginService;
     _recentCoursesService  = recentCoursesService;
     _uniwikiContext        = uniwikiContext;
 }
Exemple #16
0
 public LoginService(ProfileRepository profileRepository, IHashService hashService, TextService textService, ITimeService timeService, LoginTokenRepository loginTokenRepository, IInputValidationService inputValidationService, UniwikiContext uniwikiContext)
 {
     _profileRepository      = profileRepository;
     _hashService            = hashService;
     _textService            = textService;
     _timeService            = timeService;
     _loginTokenRepository   = loginTokenRepository;
     _inputValidationService = inputValidationService;
     _uniwikiContext         = uniwikiContext;
 }
Exemple #17
0
 public UploadPostFileServerAction(IServiceProvider serviceProvider, ProfileRepository profileRepository, PostFileRepository postFileRepository, ITimeService timeService, IUploadFileService uploadFileService, ILogger <UploadPostFileServerAction> logger, IFileHelperService fileHelperService, CourseRepository courseRepository, TextService textService, UniwikiContext uniwikiContext) : base(serviceProvider)
 {
     _profileRepository  = profileRepository;
     _postFileRepository = postFileRepository;
     _timeService        = timeService;
     _uploadFileService  = uploadFileService;
     _logger             = logger;
     _fileHelperService  = fileHelperService;
     _courseRepository   = courseRepository;
     _textService        = textService;
     _uniwikiContext     = uniwikiContext;
 }
 public RegisterServerAction(IServiceProvider serviceProvider, ProfileRepository profileRepository, ITimeService timeService, TextService textService, StringStandardizationService stringStandardizationService, IHashService hashService, EmailConfirmationSenderService emailConfirmationSenderService, StudyGroupRepository studyGroupRepository, RecentCoursesService recentCoursesService, UniwikiContext uniwikiContext)
     : base(serviceProvider)
 {
     _profileRepository              = profileRepository;
     _timeService                    = timeService;
     _textService                    = textService;
     _stringStandardizationService   = stringStandardizationService;
     _hashService                    = hashService;
     _emailConfirmationSenderService = emailConfirmationSenderService;
     _studyGroupRepository           = studyGroupRepository;
     _recentCoursesService           = recentCoursesService;
     _uniwikiContext                 = uniwikiContext;
 }
 public PostLikeRepository(UniwikiContext uniwikiContext, TextService textService)
 {
     _uniwikiContext = uniwikiContext;
     _textService    = textService;
 }
Exemple #20
0
 public PostFileService(PostFileRepository postFileRepository, UniwikiContext uniwikiContext)
 {
     _postFileRepository = postFileRepository;
     _uniwikiContext     = uniwikiContext;
 }
Exemple #21
0
 public RemovePostCommentServerAction(IServiceProvider serviceProvider, UniwikiContext uniwikiContext) : base(serviceProvider)
 {
     _uniwikiContext = uniwikiContext;
 }
Exemple #22
0
        public IQueryable <TModel> FindById(TId id) => All.Where(m => m.Id.Equals(id)); //?? throw new RequestException(notFoundMessage ?? NotFoundByIdMessage);

        public RepositoryBase(UniwikiContext uniwikiContext, DbSet <TModel> all)
        {
            UniwikiContext = uniwikiContext;
            All            = all;
        }
Exemple #23
0
 public PostCommentRepository(UniwikiContext uniwikiContext)
 // : base(uniwikiContext, uniwikiContext.PostComments)
 {
     _uniwikiContext = uniwikiContext;
 }
 public GetProfileServerAction(IServiceProvider serviceProvider, ProfileRepository profileRepository, UniwikiContext uniwikiContext, TextService textService) : base(serviceProvider)
 {
     _profileRepository = profileRepository;
     _uniwikiContext    = uniwikiContext;
     _textService       = textService;
 }
Exemple #25
0
 public PostRepository(UniwikiContext uniwikiContext)
 {
     _uniwikiContext = uniwikiContext;
 }
 public GetUniversitiesAndStudyGroupsServerAction(IServiceProvider serviceProvider, UniversityRepository universityRepository, UniwikiContext uniwikiContext) : base(serviceProvider)
 {
     _universityRepository = universityRepository;
     _uniwikiContext       = uniwikiContext;
 }
 public NewPasswordSecretRepository(UniwikiContext uniwikiContext, TextService textService)
     : base(uniwikiContext, uniwikiContext.NewPasswordSecrets)
 {
     _textService = textService;
 }
 public PostFileDownloadRepository(UniwikiContext uniwikiContext, TextService textService)
     : base(uniwikiContext, uniwikiContext.PostFileDownloads)
 {
     _textService = textService;
 }
 public StudyGroupRepository(UniwikiContext uniwikiContext, StringStandardizationService stringStandardizationService, TextService textService) : base(uniwikiContext, uniwikiContext.StudyGroups)
 {
     _textService = textService;
 }
Exemple #30
0
 public UniversityRepository(UniwikiContext uniwikiContext, StringStandardizationService stringStandardizationService, TextService textService) : base(uniwikiContext, uniwikiContext.Universities)
 {
     _stringStandardizationService = stringStandardizationService;
     _textService = textService;
 }