public IActionResult Ocijeni(int clanID, int ocjena, int teretanaID) { MyContext db = new MyContext(); OcjenaTeretane nova = new OcjenaTeretane() { ClanID = clanID, TeretanaID = teretanaID, Ocjena = ocjena }; db.OcjenaTeretane.Add(nova); db.SaveChanges(); return(RedirectToAction("Prikaz")); }
public int OcijeniTest(int clanID, int ocjena, int teretanaID) { MyContext db = new MyContext(); OcjenaTeretane nova = new OcjenaTeretane() { ClanID = clanID, TeretanaID = teretanaID, Ocjena = ocjena }; db.OcjenaTeretane.Add(nova); db.SaveChanges(); int Ocjena = ocjena; return(Ocjena); }