示例#1
0
        public static List <PersonViewModel> GetPersonList(int Country, int Ages, string Education, int Nationality, string Gender)
        {
            List <PersonViewModel> List = new List <PersonViewModel>();

            PersonDAL.GetPersonsList(Country, Ages, Education, Nationality, Gender).ForEach(r => List.Add(new PersonViewModel(r)));
            return(List);
        }
示例#2
0
        public static List <PersonViewModel> GetPersonList()
        {
            List <PersonViewModel> List = new List <PersonViewModel>();

            PersonDAL.GetPersonsList().ForEach(r => List.Add(new PersonViewModel(r)));
            return(List);
        }
示例#3
0
        // GET: ControlPanel
        public ActionResult Index()
        {
            if (UserHelpar.GetUserType() != "Admin")
            {
                return(RedirectToAction("Unauthorized", "Home", null));
            }

            var persons = PersonDAL.GetPersonsList();

            ViewBag.PersonCount = persons.Count;

            var RegisterRequest = RegisterRequestsDAL.Get_RegisterRequestsList();

            ViewBag.RegisterRequestCount = RegisterRequest.Count;

            var RelationRequest = RelationRequestDAL.GetRelationRequestList();

            ViewBag.RelationRequestCount = RelationRequest.Count;

            return(View());
        }