示例#1
0
        public ActionResult Create()
        {
            //if (Session["LogedUserID"] != null)
            //{


            try
            {
                var allergy = db.SP_SelectAllergy();
                return(View(allergy));
            }
            catch (Exception ex)
            {
                ViewBag.errorMessage = "Error occurred while loading data.";
                return(View());
            }
            //}
            // else
            //{

            //    return RedirectToAction("AdminLogin", "Account");
            // }
        }