Ejemplo n.º 1
0
        public static UserFullModel Convert(User user)
        {
            UserFullModel model = new UserFullModel
            {
                UserId = user.Id,
                Picture = user.Picture,
                Username = user.Username,
                IsOnline =user.IsOnline,
                PostCount = user.Posts.Count,
                ChatRoomCount = user.ChatRooms.Count
            };

            return model;
        }
Ejemplo n.º 2
0
        public static UserFullModel Convert(User user)
        {
            UserFullModel model = new UserFullModel
            {
                UserId        = user.Id,
                Picture       = user.Picture,
                Username      = user.Username,
                IsOnline      = user.IsOnline,
                PostCount     = user.Posts.Count,
                ChatRoomCount = user.ChatRooms.Count
            };

            return(model);
        }