public ActionResult addonowner(int owid = 0) { OwnerAddOn ui = new OwnerAddOn(); ui.OwnerId = owid; return(View(ui)); }
public ActionResult addonowner(OwnerAddOn et) { if (ModelState.IsValid) { db.OwnerAddOns.Add(et); db.SaveChanges(); ViewBag.message = "owner added sucessfully"; return(RedirectToAction("Index")); } return(View()); }