public PostRecord(Post i_Post) { r_Post = i_Post; }
public abstract string SortFeedOnRequest(Post i_Post);
private void loadWallPost(Post i_CurrentPost) { bool isPostSupported = false; if (i_CurrentPost.Message != null) { LabelWallPost.Text = i_CurrentPost.Message; isPostSupported = true; } if (i_CurrentPost.PictureURL != null) { PictureBoxWallPost.LoadAsync(i_CurrentPost.PictureURL); isPostSupported = true; } if (i_CurrentPost.Comments != null) { foreach(Comment currentComment in i_CurrentPost.Comments) { if (currentComment.Message != null) { ListBoxWallComments.Items.Add(string.Format("{0}: {1}", currentComment.From.Name, currentComment.Message)); } else { ListBoxWallComments.Items.Add(string.Format("{0}: <Unsupported type>", currentComment.From.Name)); } } } if (!isPostSupported) { LabelWallPost.Text = string.Format("<Post of type {0} are currently not supported>", i_CurrentPost.Type); } }
public override string SortFeedOnRequest(Post i_Post) { return i_Post.Link; }
public PostViewController(Post p) : base() { post = p; }
public override string SortFeedOnRequest(Post i_Post) { return i_Post.Description; }
public IList<Tag> GetPostTags(Post post) { return _blogRepository.GetPostTags(post); }
public IList<PostImage> GetPostImages(Post post) { return _blogRepository.GetPostImages(post); }
public IList<Category> GetPostCategories(Post post) { return _blogRepository.GetPostCategories(post); }
public ActionResult AddNewPost(PostViewModel model) { var post = new Post { Id = model.ID, Body = model.Body, Meta = model.Meta, PostedOn = DateTime.Now, Published = true, ShortDescription = model.ShortDescription, Title = model.Title, UrlSeo = model.UrlSeo }; _blogRepository.AddNewPost(post); //provlima me to url kai to offline string desc = System.Net.WebUtility.HtmlDecode(model.ShortDescription); string finaldesc= Regex.Replace(desc, @"<[^>]*>", String.Empty); string message = "http://localhost:52815/Blog/Post?slug="+ System.Net.WebUtility.HtmlDecode(model.UrlSeo) + " " + finaldesc; long userId = 100010771963874; string wallAccessToken = "CAARfEI0GudoBACp8ZAsnrDH1mYnbxFr0jIAqpOp8DQfDij1ihI7Kt7ORQFEplI7F0WZCpNGYvTbZC7DTZA33s5FZBtTZCkWs9xyPdaPuQizxXHPM06Sf5TIoAx6sqCYdKqsnJTeddefjSdMaL6Q1L1ZCblZAEk384V01gcZBjqRroeiXqMxWuBNtqKf8iK2MgT90ZD&expires=5183999"; PostToWall(message, userId, wallAccessToken); return RedirectToAction("AllPosts", "Blog", new { slug = model.UrlSeo }); }