public async Task CrearBlog(EditorBlog editorBlog) { var post = BlogEntidad.CrearNuevoPorDefecto(); post.CopiaValores(editorBlog); _db.Blogs.Add(post); await _db.SaveChangesAsync(); editorBlog.Id = post.Id; }
private async Task ActualizarBlog(EditorBlog editorBlog) { await _blogServicio.ActualizarBlog(editorBlog); }
private async Task CrearBlog(EditorBlog editorBlog) { await _blogServicio.CrearBlog(editorBlog); }
public async Task ActualizarBlog(EditorBlog editorBlog) { var post = await RecuperarBlog(editorBlog.Id); post.CopiaValores(editorBlog); await _db.SaveChangesAsync(); }