Пример #1
0
 public TeamModelWithCountries(TeamModel model, CountryCollectionModel countries) : this(countries)
 {
     Id        = model.Id;
     Name      = model.Name;
     ImageFlag = model.ImageFlag;
     CountryId = model.CountryId;
     TeamKey   = model.TeamKey;
 }
Пример #2
0
 public StadiumModelWithCountries(StadiumModel model, CountryCollectionModel countries) : this(countries)
 {
     Id          = model.Id;
     Name        = model.Name;
     Description = model.Description;
     Capacity    = model.Capacity;
     ImageUrl    = model.ImageUrl;
     CountryId   = model.CountryId;
 }
Пример #3
0
 public TeamModelWithCountries(CountryCollectionModel countries)
 {
     Countries = countries;
 }
Пример #4
0
 public StadiumModelWithCountries(CountryCollectionModel countries)
 {
     Countries = countries;
 }
Пример #5
0
        public async Task <ActionResult> Index()
        {
            CountryCollectionModel model = await CountryService.GetAllCountries();

            return(View(model));
        }
Пример #6
0
        private async Task <TeamModelWithCountries> GetTeamWithCountries(TeamIdModel team, CountryCollectionModel countries)
        {
            if (team == null)
            {
                return(new TeamModelWithCountries(countries));
            }
            else
            {
                var model = await this.Get(team);

                return(new TeamModelWithCountries(model, countries));
            }
        }
Пример #7
0
        private async Task <StadiumModelWithCountries> GetStadiumWithCountries(StadiumIdModel stadium, CountryCollectionModel countries)
        {
            if (stadium == null)
            {
                return(new StadiumModelWithCountries(countries));
            }
            else
            {
                var model = await this.GetStadium(stadium);

                return(new StadiumModelWithCountries(model, countries));
            }
        }