Наследование: BoolModel
Пример #1
0
 public Repository()
 {
     Name = "";
     Owner = new User
     {
         Login = ""
     };
 }
Пример #2
0
 public ProfileRequestDataModel()
 {
     User = new User
     {
         Name = "Alberto Monteiro",
         Login = "******",
         Location = "Brazil",
         AvatarUrl = @"https://pt.gravatar.com/userimage/11089328/847bb84cca2c25b56dacf1bafc6107ae.jpg?size=200",
         Blog = @"http://blog.albertomonteiro.net"
     };
 }
Пример #3
0
        public AboutDataModel()
        {
            Michelsalib = new User
            {
                Login = "******",
                Name = "Michel Salib",
                AvatarUrl = "https://secure.gravatar.com/avatar/5c4663b12b9e6d8dc6dcdfbfb3dc1317"
            };

            AlbertoMonteiro = new User
            {
                Login = "******",
                Name = "Alberto Monteiro",
                AvatarUrl = "http://pt.gravatar.com/userimage/11089328/847bb84cca2c25b56dacf1bafc6107ae"
            };
        }
Пример #4
0
 public void LoadView(GithubService githubService)
 {
     if (User == null)
     {
         User = _githubService.Load(new UserRequest(_githubService.Username), u =>
         {
             User = u;
             _githubService.Load(new UserOrganizationRequest(_githubService.Username), organizations =>
             {
                 foreach (var organization in organizations)
                 {
                     Organizations.Add(organization);
                 }
             });
         });
     }
 }
Пример #5
0
        public AboutDataModel()
        {
            Michelsalib = new User
            {
                Login = "******",
                Name = "Michel Salib",
                AvatarUrl = "https://secure.gravatar.com/avatar/5c4663b12b9e6d8dc6dcdfbfb3dc1317"
            };

            AlbertoMonteiro = new User
            {
                Login = "******",
                Name = "Alberto Monteiro",
                AvatarUrl = "http://pt.gravatar.com/userimage/11089328/847bb84cca2c25b56dacf1bafc6107ae"
            };

            Zeromax = new User
            {
                Login = "******",
                Name = "Andreas Nölke",
                AvatarUrl = "https://avatars2.githubusercontent.com/u/1867177"
            };

            NPadrutt = new User
            {
                Login = "******",
                Name = "Nino Padrutt",
                AvatarUrl = "https://avatars3.githubusercontent.com/u/1764367"
            };

            Jonnybest = new User
            {
                Login = "******",
                Name = "jonnybest",
                AvatarUrl = "https://avatars2.githubusercontent.com/u/187852"
            };

            RandomlyKnighted = new User
            {
                Login = "******",
                Name = "Tyler Hughes",
                AvatarUrl = "https://avatars0.githubusercontent.com/u/2483249"
            };
        }
Пример #6
0
        public RepositoryDataModel()
        {
            var user = new User
            {
                Login = "******",
                AvatarUrl = "https://secure.gravatar.com/avatar/5c4663b12b9e6d8dc6dcdfbfb3dc1317",
            };

            Repository = new Repository
            {
                Owner = user,
                Name = "symfony",
                HtmlUrl = "http://github.com/michelsalib/symfony",
                Description = "The Symfony2 PHP framework",
                Watchers = 3,
                Forks = 1,
                Homepage = "symfony.com",
                Parent = new Repository
                {
                    Owner = user,
                    Name = "symfnoy"
                }
            };

            Tree = new GitTree()
            {
                Tree = new List<Gi7.Client.Model.GitHubFile>()
                {
                    new Gi7.Client.Model.GitHubFile() {
                        Path = "readme.md",
                        Type = "blob",
                    },
                    new Gi7.Client.Model.GitHubFile() {
                        Path = "dir",
                        Type = "tree",
                    },
                }
            };

            Commits = new ObservableCollection<Push>
            {
                new Push
                {
                    Author = user,
                    Commit = new Commit
                    {
                        Message = "Removing static access to Username on github service",
                        Author = new Committer
                        {
                            Date = DateTime.Now,
                        }
                    }
                }
            };

            PullRequests = new ObservableCollection<PullRequest>
            {
                new PullRequest
                {
                    Title = "my pull requets",
                    Body = "the description",
                    UpdatedAt = DateTime.Now,
                    State = "Open",
                    User = user,
                }
            };

            Issues = new ObservableCollection<Issue>
            {
                new Issue
                {
                    Title = "my issue",
                    Body = "the description is very long the description is very long the description is very long the description is very long the description is very long the description is very long the description is very long",
                    UpdatedAt = DateTime.Now,
                    State = "Open",
                    User = user,
                }
            };
        }
Пример #7
0
 private static void OnUserSelected(INavigationService navigationService, User user)
 {
     if (user != null)
         navigationService.NavigateTo(string.Format(ViewModelLocator.USER_URL, user.Login));
 }