public ActionResult Edit([Bind(Include = "SifraKontinent,NazivKontinentHr,NazivKontinentEng")] Kontinent kontinent) { if (ModelState.IsValid) { db.Entry(kontinent).State = EntityState.Modified; db.SaveChanges(); return(RedirectToAction("Index")); } return(View(kontinent)); }
public ActionResult Edit([Bind(Include = "SifraDrzava,SifraKontinent,GlavniGrad,Zastava,BrojStanovnika,NazivDrzavaHr,NazivDrzavaEng")] Drzava drzava) { if (ModelState.IsValid) { db.Entry(drzava).State = EntityState.Modified; db.SaveChanges(); return(RedirectToAction("Index")); } ViewBag.SifraKontinent = new SelectList(db.Kontinent, "SifraKontinent", "NazivKontinentHr", drzava.SifraKontinent); return(View(drzava)); }