public ActionResult Edit([Bind(Include = "Id,Title")] Image image) { if (ModelState.IsValid) { db.Entry(image).State = EntityState.Modified; db.SaveChanges(); return(RedirectToAction("Index")); } return(View(image)); }
public ActionResult Edit([Bind(Include = "Id,Name,Power,SideEffect,Description,MedicineTypeId,CompanyId,ShopId,ImageId,VideoId")] Medicine medicine) { if (ModelState.IsValid) { db.Entry(medicine).State = EntityState.Modified; db.SaveChanges(); return(RedirectToAction("Index")); } return(View(medicine)); }
public ActionResult Edit([Bind(Include = "Id,Name,Description")] FeedType feedType) { if (ModelState.IsValid) { db.Entry(feedType).State = EntityState.Modified; db.SaveChanges(); return(RedirectToAction("Index")); } return(View(feedType)); }
public ActionResult Edit([Bind(Include = "Id,Name,Link")] Video video) { if (ModelState.IsValid) { db.Entry(video).State = EntityState.Modified; db.SaveChanges(); return(RedirectToAction("Index")); } return(View(video)); }
public ActionResult Edit([Bind(Include = "Id,Name,Sign,FirstAid,Description,MedicineTypeId,ImageId,VideoId")] Disease disease) { if (ModelState.IsValid) { db.Entry(disease).State = EntityState.Modified; db.SaveChanges(); return(RedirectToAction("Index")); } return(View(disease)); }
public ActionResult Edit([Bind(Include = "Id,Name")] Country country) { if (ModelState.IsValid) { db.Entry(country).State = EntityState.Modified; db.SaveChanges(); return(RedirectToAction("Index")); } return(View(country)); }
public ActionResult Edit([Bind(Include = "Id,Name,Contact,Description,CityId,ImageId")] Company company) { if (ModelState.IsValid) { db.Entry(company).State = EntityState.Modified; db.SaveChanges(); return RedirectToAction("Index"); } ViewBag.CityId = new SelectList(db.City, "Id", "Name", company.CityId); return View(company); }
public ActionResult Edit([Bind(Include = "Id,Name,Contact,Location,Description,CityId")] Shop shop) { if (ModelState.IsValid) { db.Entry(shop).State = EntityState.Modified; db.SaveChanges(); return(RedirectToAction("Index")); } ViewBag.CityId = new SelectList(db.City, "Id", "Name", shop.CityId); return(View(shop)); }
public ActionResult Edit([Bind(Include = "Id,Name,Description,FeedTypeId,CompanyId,ShopId,ImageId,VideoId")] Feed feed) { if (ModelState.IsValid) { db.Entry(feed).State = EntityState.Modified; db.SaveChanges(); return(RedirectToAction("Index")); } ViewBag.FeedTypeId = new SelectList(db.FeedType, "Id", "Name", feed.FeedTypeId); return(View(feed)); }
public ActionResult Edit([Bind(Include = "Id,Name,CountryId")] City city) { if (ModelState.IsValid) { db.Entry(city).State = EntityState.Modified; db.SaveChanges(); return(RedirectToAction("Index")); } ViewBag.CountryId = new SelectList(db.Country, "Id", "Name", city.CountryId); return(View(city)); }