public ActionResult CreateBait() { var createBait = new CreateBaitViewModel() { Fishes = db.Fishes.ToList() }; return(PartialView(createBait)); }
public ActionResult UpdateBait(int Id) { var hook = db.Baits.First(x => x.Id == Id); var baitView = new CreateBaitViewModel() { Id = Id, Description = hook.Description, Fishes = db.Fishes.ToList(), Name = hook.Name, Image = hook.Image }; return(View("CreateBait", baitView)); }