public ActionResult Edit([Bind(Include = "CompId,CompPay")] Compensation compensation) { if (ModelState.IsValid) { db.Entry(compensation).State = EntityState.Modified; db.SaveChanges(); return(RedirectToAction("Index")); } return(View(compensation)); }
public ActionResult Edit([Bind(Include = "RegionId,RegionName")] Region region) { if (ModelState.IsValid) { db.Entry(region).State = EntityState.Modified; db.SaveChanges(); return(RedirectToAction("Index")); } return(View(region)); }
public ActionResult Edit([Bind(Include = "FollowerId,FollowerCount")] Follower follower) { if (ModelState.IsValid) { db.Entry(follower).State = EntityState.Modified; db.SaveChanges(); return(RedirectToAction("Index")); } return(View(follower)); }
public ActionResult Edit([Bind(Include = "PostId,PostNum")] Post post) { if (ModelState.IsValid) { db.Entry(post).State = EntityState.Modified; db.SaveChanges(); return(RedirectToAction("Index")); } return(View(post)); }
public ActionResult Edit([Bind(Include = "BrandId,CompanyName,Product,ProductDescription,PostId,CompId")] Brand brand) { if (ModelState.IsValid) { db.Entry(brand).State = EntityState.Modified; db.SaveChanges(); return(RedirectToAction("Index")); } ViewBag.CompId = new SelectList(db.Compensations, "CompId", "CompPay", brand.CompId); ViewBag.PostId = new SelectList(db.Posts, "PostId", "PostNum", brand.PostId); return(View(brand)); }
public ActionResult Edit([Bind(Include = "SociaLId,Name,SocailMName,FollowerCountId,RegionId,CompId,Email,Image_")] SocialUser socialUser) { if (ModelState.IsValid) { db.Entry(socialUser).State = EntityState.Modified; db.SaveChanges(); return(RedirectToAction("Index")); } ViewBag.CompId = new SelectList(db.Compensations, "CompId", "CompPay", socialUser.CompId); ViewBag.FollowerCountId = new SelectList(db.Followers, "FollowerId", "FollowerCount", socialUser.FollowerCountId); ViewBag.RegionId = new SelectList(db.Regions, "RegionId", "RegionName", socialUser.RegionId); return(View(socialUser)); }