Exemple #1
0
        public async Task <IActionResult> GetByGuid(Guid guid)
        {
            var post = await _postDal.GetPostById(guid, null, null);

            return(post != null ? (IActionResult)this.Ok(post) : this.NotFound());
        }
Exemple #2
0
        public async Task <PostModel> GetPostById(Guid?guid, int?legacyId, string uniqueName, bool isAdmin)
        {
            var post = await _postDal.GetPostById(guid, legacyId, uniqueName);

            return((post == null || isAdmin || post.VisibleFlag) ? post : null);
        }
 public PostDTO GetPostById(int id)
 {
     return(_dal.GetPostById(id));
 }
Exemple #4
0
 public Post GetPostById(int postId)
 {
     return(_postDal.GetPostById(postId));
 }