public ActionResult Edit([Bind(Include = "EventId,EventName,EventDescription,Location,StartDateTime,EndDateTime,ContactPerson,ContactDetails,Likes,IsLike")] Event @event) { if (ModelState.IsValid) { db.Entry(@event).State = EntityState.Modified; db.SaveChanges(); return(RedirectToAction("Index")); } return(View(@event)); }
public ActionResult Edit([Bind(Include = "UserId,FirstName,LastName,Email,Password,ZipCode,Height,Weight,Gender,DateOfBirth")] User user) { if (ModelState.IsValid) { db.Entry(user).State = EntityState.Modified; db.SaveChanges(); return(RedirectToAction("Index")); } return(View(user)); }
public ActionResult Edit([Bind(Include = "CId,CDescription,CDateTime,EventEventId")] Comments comments) { if (ModelState.IsValid) { db.Entry(comments).State = EntityState.Modified; db.SaveChanges(); return(RedirectToAction("Index")); } ViewBag.EventEventId = new SelectList(db.Events, "EventId", "EventName", comments.EventEventId); return(View(comments)); }
public ActionResult Edit([Bind(Include = "ConsultationId,StartDT,EndDT,RDescription,Status,UserUserId")] Consultation consultation) { if (ModelState.IsValid) { db.Entry(consultation).State = EntityState.Modified; db.SaveChanges(); return(RedirectToAction("Index")); } ViewBag.UserUserId = new SelectList(db.Users, "UserId", "FirstName", consultation.UserUserId); return(View(consultation)); }
public ActionResult Edit([Bind(Include = "EmailId,ToEmail,Subject,Contents,EventEventId")] Email email) { if (ModelState.IsValid) { db.Entry(email).State = EntityState.Modified; db.SaveChanges(); return(RedirectToAction("Index")); } ViewBag.EventEventId = new SelectList(db.Events, "EventId", "EventName", email.EventEventId); return(View(email)); }
public ActionResult Edit([Bind(Include = "UserUserId,EventEventId")] EventMember eventMember) { if (ModelState.IsValid) { db.Entry(eventMember).State = EntityState.Modified; db.SaveChanges(); return(RedirectToAction("Index")); } ViewBag.UserUserId = new SelectList(db.Users, "UserId", "FirstName", eventMember.UserUserId); ViewBag.EventEventId = new SelectList(db.Events, "EventId", "EventName", eventMember.EventEventId); return(View(eventMember)); }