// GET: Site public ActionResult Index() { if (Session["employee"] == null) { return(RedirectToAction("Login", "Login", new { returnurl = HttpContext.Request.Url })); } else { o_sites = new CSiteList(); o_sites.Load(); ViewBag.Message = "All Active Sites"; return(View(o_sites)); } }
// GET: Event/Create public ActionResult Create() { if (Session["employee"] == null) { return(RedirectToAction("Login", "Login", new { returnurl = HttpContext.Request.Url })); } else { EventsSites oEvenSitesList = new EventsSites(); CSiteList allsites = new CSiteList(); allsites.Load(); oEvenSitesList.AllSites = allsites; oEvenSitesList.NewEvent = new CEvents(); return(View(oEvenSitesList)); } }