Пример #1
0
 public MainPostQueryService(
     IMathHubDbContext mathHubDbContext,
     IPostQueryService postQueryService)
 {
     this.ctx = mathHubDbContext.GetDbContext();
     this._postQueryService = postQueryService;
 }
Пример #2
0
 public UserQueryService(
     IMathHubDbContext MathHubDbContext,
     IAuthenticationService authenticationService)
 {
     ctx = MathHubDbContext.GetDbContext();
     this._authenticationService = authenticationService;
 }
Пример #3
0
 public CommentCommandService(
     IRepository<Comment> commentRepository,
     IMathHubDbContext context)
 {
     this.ctx = context.GetDbContext();;
     this.commentRepository = commentRepository;
 }
Пример #4
0
 public DiscussionCommandService(
     IRepository<Discussion> discussionRepository,
     IMathHubDbContext context)
 {
     this.ctx = context.GetDbContext();
     this.discussionRepository = discussionRepository;
 }
Пример #5
0
 public BlogCommandService(
     IRepository<Blog> blogRepository,
     IMathHubDbContext context)
 {
     this.ctx = context.GetDbContext();
     this.blogRepository = blogRepository;
 }
Пример #6
0
 public ProblemQueryService(
     IMathHubDbContext mathHubDbContext,
     IUserQueryService userQueryService,
     IMainPostQueryService mainPostQueryService)
 {
     ctx = mathHubDbContext.GetDbContext();
     this._userQueryService = userQueryService;
     this._mainPostQueryService = mainPostQueryService;
 }
Пример #7
0
 public TagCommandService(
     IMathHubDbContext ctx,
     IRepository<Tag> tagRepository,
     ILogger logger)
 {
     this.ctx = ctx.GetDbContext();
     this.tagRepository = tagRepository;
     this.logger = logger;
 }
Пример #8
0
 public FormAuthenticationService(IMathHubDbContext mathHubDbContext)
 {
     // temporary login with Thanh Hai User
     ctx = mathHubDbContext.GetDbContext();
     if (WebSecurity.IsAuthenticated)
     {
         user = ctx.Users.FirstOrDefault(t => t.Username.Equals(WebSecurity.CurrentUserName));
     }
 }
Пример #9
0
 public DiscussionQueryService(
     IRepository<Discussion> discussionRepository,
     IMathHubDbContext context,
     IMainPostQueryService mainPostQuerySerivce)
 {
     this.ctx = context.GetDbContext();
     this._discussionRepository = discussionRepository;
     this._mainPostQuerySerivce = mainPostQuerySerivce;
 }
Пример #10
0
 public ProblemCommandService(
     IMathHubDbContext MathHubDbContext,
     IRepository<Problem> problemRepository,
     IMainPostCommandService mainPostCommandService,
     ILogger logger
     )
 {
     this.ctx = MathHubDbContext.GetDbContext();
     this.problemRepository = problemRepository;
     this.mainPostCommandService = mainPostCommandService;
     this.logger = logger;
 }
Пример #11
0
 public UserCommandService(
     IMathHubDbContext context,
     IRepository<User> userRepository,
     IRepository<Profile> profileRepository,
     IRepository<Image> imageRepository,
     IRepository<Activity> activityRepository,
     ILogger logger)
 {
     this.ctx = context.GetDbContext();
     this.userRepository = userRepository;
     this.profileRepository = profileRepository;
     this.imageRepository = imageRepository;
     this.activityRepository = activityRepository;
     this.logger = logger;
 }
Пример #12
0
 public MainPostCommandService(
     IMathHubDbContext MathHubDbContext,
     IRepository<Comment> commentRepository,
     IRepository<Reply> replyRepository,
     IRepository<PostTag> postTagRepository,
     IRepository<FavoritePost> favoritePostRepository,
     IRepository<Share> shareRepository,
     IAuthenticationService authenticationService,
     ILogger logger)
 {
     this.ctx = MathHubDbContext.GetDbContext();
     this.replyRepository = replyRepository;
     this.commentRepository = commentRepository;
     this.postTagRepository = postTagRepository;
     this.authenticationService = authenticationService;
     this.favoritePostRepository = favoritePostRepository;
     this.shareRepository = shareRepository;
     this.logger = logger;
 }
Пример #13
0
 public PermissionQueryService(
     IMathHubDbContext context)
 {
     this.ctx = context.GetDbContext();
 }
Пример #14
0
 public PermissionCommandService(
     IMathHubDbContext context)
 {
     this.ctx = context.GetDbContext();
 }
Пример #15
0
 public PostQueryService(IMathHubDbContext mathHubDbContext)
 {
     this.ctx = mathHubDbContext.GetDbContext();
 }