Exemplo n.º 1
0
        public ActionResult Ranking()
        {
            bl_User blUser = new bl_User();
            var     model  = blUser.GetTop(12);

            return(View(model));
        }
Exemplo n.º 2
0
        public TopModel GetTop(Guid userId, int top = 10)
        {
            bl_User  blUser = new bl_User();
            TopModel model  = new TopModel();

            model.CurrentUser = new UserProfile(blUser.GetById(userId));
            model.UserList    = blUser.GetTop(10)
                                .Select(m => new UserProfile(m))
                                .ToList();

            return(model);
        }
Exemplo n.º 3
0
        public TopModel GetTopByZingUser(string userName, int top = 10)
        {
            bl_User  blUser = new bl_User();
            TopModel model  = new TopModel();

            //var user = blUser.GetByUserName("zing." + userName);
            var user = blUser.GetByUserName(userName);

            if (user != null)
            {
                model.CurrentUser = new UserProfile(user);
            }
            else
            {
                model.CurrentUser = null;
            }

            model.UserList = blUser.GetTop(10)
                             .Select(m => new UserProfile(m))
                             .ToList();

            return(model);
        }