public virtual TblBlogPosts PrepareTblBlogPosts(BlogPostModel post) { var result = post.Adapt <TblBlogPosts>(); result.Tags = post.PostTags?.Select(p => new TblPostTags() { Tag = p }).ToList(); result.Categories = post.PostCategories?.Select(p => new TblPostCategories() { Id = p }).ToList(); return(result); }