Пример #1
0
        public ActionResult Index(string name)
        {
            Authentication authentication = (Authentication)Session["authentication"];

            if (authentication == null)
            {
                TempData["msg"] = "<script>alert('Please Log in First');</script>";
                return(RedirectToAction("SignUpView", "SignUp"));
            }
            ViewBag.SearchName       = name;
            ViewBag.Name             = authentication.Name;
            ViewBag.SignupID         = authentication.Id;
            ViewBag.Password         = authentication.Password;
            ViewBag.NotificationList = homeManager.GetAllNotification(authentication.Id);
            List <FriendShip> persons = GetFriendShipList(name, authentication);

            ViewBag.PersonList = persons;
            ViewBag.Message    = null;
            if (persons == null)
            {
                ViewBag.Message = "No Person Found of that Name";
            }
            return(View());
        }