Beispiel #1
0
 public ActionResult Edit([Bind(Include = "Id,Name,Gender,City,Photo,AlternateText")] Myemployee myemployee)
 {
     if (ModelState.IsValid)
     {
         db.Entry(myemployee).State = EntityState.Modified;
         db.SaveChanges();
         return(RedirectToAction("Index"));
     }
     return(View(myemployee));
 }
Beispiel #2
0
 public ActionResult Edit([Bind(Include = "higesteducation,status,age,id,name")] PersonDetail personDetail)
 {
     if (ModelState.IsValid)
     {
         db.Entry(personDetail).State = EntityState.Modified;
         db.SaveChanges();
         return(RedirectToAction("Index"));
     }
     return(View(personDetail));
 }