public Client(
     IRequestManager requestManager,
     IPosts posts)
 {
     this.RequestManager = requestManager;
     Posts = posts;
 }
 public PostsController(
     IPosts postsService,
     IForums forumsService,
     UserManager <ApplicationUser> userManager)
 {
     this.postsService  = postsService;
     this.forumsService = forumsService;
     this.userManager   = userManager;
 }
Exemple #3
0
 public PostsController(IPosts _iposts, IMultipleImageData _imageData,
                        IWebHostEnvironment _env,
                        IMapper _map)
 {
     this._map      = _map;
     this.iposts    = _iposts;
     this.imageData = _imageData;
     this.env       = _env;
 }
Exemple #4
0
 public AdminController(IAdmin authProvider, IPosts blogRepository = null, IFeedback feedbackRepository = null, IUsligi services = null, IPhoto photo = null, ICategories cat = null)
 {
     _blogRepository     = blogRepository;
     _authProvider       = authProvider;
     _feedbackRepository = feedbackRepository;
     _servicesRepository = services;
     _photoRepository    = photo;
     _catRepository      = cat;
 }
Exemple #5
0
 public PostsResults(IPosts iPosts)
 {
     Id            = iPosts.Id;
     UserId        = iPosts.UserId;
     UserOwnerName = iPosts.UserOwnerName;
     Title         = iPosts.Title;
     ImgLink       = iPosts.ImgLink;
     LikeCount     = iPosts.LikeCount;
     ViewCount     = iPosts.ViewCount;
     CommentsCount = iPosts.CommentsCount;
 }
        //tap on a post and it will expand on it allow you to like or private message


        private void viewPost_ItemSelected(object sender, SelectedItemChangedEventArgs e)
        {
            post = (IPosts)e.SelectedItem;
            if (stackCreatePost.IsVisible == false)
            {
                if (post != null)
                {
                    txtViewPost.Text        = post.Post;
                    stackPosts.IsVisible    = false;
                    stackViewPost.IsVisible = true;

                    HomeBackend hBackend = new HomeBackend();
                    hBackend.GetCommentsInfo(post.Id);
                    if (hBackend.CommentsList != null)
                    {
                        lstComments.ItemsSource = hBackend.CommentsList;
                    }
                }
            }
        }
 public PostsController(IPosts posts)
 {
     this.posts = posts;
 }
Exemple #8
0
 public BlogController()
 {
     postsService = new PostsService();
 }
Exemple #9
0
 public ManageModel(IPosts post, IConfiguration configuration)
 {
     _post = post;
     ///Reference to blob storage account gateway to storage account
     BlobImage = new Models.Utilities.Blob(configuration);
 }
Exemple #10
0
 public HomeController(IPosts postsService)
 {
     this.postsService = postsService;
 }
 public ForumsController(IForums forumsService, IPosts postsService)
 {
     this.forumsService = forumsService;
     this.postsService  = postsService;
 }
Exemple #12
0
 public BlogController(IPosts blogRepository, IPhoto photoRepository, ICategories categoryRepository)
 {
     _blogRepository     = blogRepository;
     _photoRepository    = photoRepository;
     _categoryRepository = categoryRepository;
 }
Exemple #13
0
        public WidgetViewModel(IPosts blogRepository)
        {
            Categories = blogRepository.CategoriesList();

            LatestPosts = blogRepository.PostsList();
        }
Exemple #14
0
 public PhotoViewModel(int year, int month, string title, IPhoto photoRepository, IPosts blogRepository)
 {
     LatestPosts = blogRepository.Post(year, month, title);
     if (LatestPosts != null)
     {
         var post = mapping.GetPostsById(LatestPosts.id);
         if (post.Album != null)
         {
             Photos = photoRepository.PhotosForAlbum(post.Album.id);
         }
     }
 }
Exemple #15
0
 /// <summary>
 /// Constructor controller
 /// </summary>
 /// <param name="context">ApplicationDbContext of application</param>
 /// <param name="mapper">Interface to map over DTO's</param>
 /// <returns></returns>
 public PostsController(ApplicationDbContext context, IMapper mapper)
 {
     _postsDomain = new PostRepository(context, mapper);
 }
 public CreatePostModel(IPosts post, IConfiguration configuration)
 {
     _posts = post;
     // Blob Storage Account to use in page
     BlobImage = new Blob(configuration);
 }
 public DetailsModel(IPosts post)
 {
     _posts = post;
 }
Exemple #18
0
 public PostDetailsResult(IPosts iPosts) : base(iPosts)
 {
 }
 public PostsController()
 {
     postService = new PostsService();
 }
        public AdminController()
        {
            var bl = new BusinessLogic.BusinessLogic();

            _posts = bl.GetPosts();
        }
 public PostsController(IPosts postService)
 {
     this.postService = postService;
 }
Exemple #22
0
 public EditModel(IPosts posts)
 {
     _posts = posts;
 }
Exemple #23
0
 public IndexModel(IPosts post, IComment comment)
 {
     _post    = post;
     _comment = comment;
 }