常用方法
常用方法
常用方法
常用方法
public IActionResult Edit(PostViewModel post) { if (!ModelState.IsValid) { return(View()); } post.Author = User.Identity.Name; post.Posted = DateTime.Now; var postUpdate = _blog.Edit(post); return(RedirectToAction("Post", "Blog", new //passing the Post parameters { post.Id })); }