public ActionResult Edit(RateableProperty rateableproperty) { if (ModelState.IsValid) { db.Entry(rateableproperty).State = EntityState.Modified; db.SaveChanges(); return RedirectToAction("Index"); } return View(rateableproperty); }
public ActionResult Create(RateableProperty rateableproperty) { if (ModelState.IsValid) { db.Properties.Add(rateableproperty); db.SaveChanges(); return RedirectToAction("Index"); } return View(rateableproperty); }