// // GET: /AdminNews/Create public ActionResult Create() { activity activity = new activity() { }; return View(activity); }
public ActionResult Create(activity activity) { try { UpdateModel(activity); ActivitiesRepository.Add(activity); ActivitiesRepository.Save(); return RedirectToAction("Index", new { id = activity.id }); } catch { return View(activity); } }
public void Delete(activity activity) { db.activities.DeleteOnSubmit(activity); }
public void Add(activity activity) { db.activities.InsertOnSubmit(activity); }
partial void Deleteactivity(activity instance);
partial void Updateactivity(activity instance);
partial void Insertactivity(activity instance);