public Seed(UserManager <User> userManager,
                    RoleManager <Role> roleManager,
                    IUnitOfWork unitOfWork,
                    ISeasonRepository seasonRepository,
                    IStadiumRepository stadiumRepository,
                    IClubRepository clubRepository,
                    ISquadRepository squadRepository,
                    IKitRepository kitRepository,
                    IManagerRepository managerRepository,
                    IPlayerRepository playerRepository)
        {
            _userManager       = userManager;
            _roleManager       = roleManager;
            _unitOfWork        = unitOfWork;
            _seasonRepository  = seasonRepository;
            _stadiumRepository = stadiumRepository;
            _clubRepository    = clubRepository;
            _squadRepository   = squadRepository;
            _kitRepository     = kitRepository;
            _managerRepository = managerRepository;
            _playerRepository  = playerRepository;

            _jsonSerializerSettings = new JsonSerializerSettings
            {
                NullValueHandling     = NullValueHandling.Ignore,
                MissingMemberHandling = MissingMemberHandling.Ignore
            };
        }
 /// <summary>
 ///  Initializes a new istance of the <see cref="StadiumsController"/> class.
 /// </summary>
 /// <param name="_context">Context instance</param>
 /// <param name="_logger">Logger instance</param>
 /// <param name="_mapper">Mapper instance</param>
 public StadiumsController(FootballManagerContext context, IStadiumRepository repository, ILogger <StadiumsController> logger, IMapper mapper)
 {
     _context    = context;
     _repository = repository;
     _logger     = logger;
     _mapper     = mapper;
 }
 public AddStadiumCommandHandler(IStadiumRepository stadiumRepository, ITeamRepository teamRepository, IMapper mapper, ILogger <AddStadiumCommandHandler> logger)
     : base(logger)
 {
     _mapper            = mapper;
     _stadiumRepository = stadiumRepository;
     _teamRepository    = teamRepository;
 }
 public ScheduleService(
     IMatchRepository matchRepo,
     IStadiumRepository stadiumRepo,
     IReservationRepository reservationRepository,
     IReservationService resService)
 {
     _matchRepo             = matchRepo;
     _stadiumRepo           = stadiumRepo;
     _reservationRepository = reservationRepository;
     _resService            = resService;
 }
 public GameSlateRepository(IGameRepository gameRepository,
                            ITeamRepository teamRepository,
                            IGameTeamRepository gameTeamRepository,
                            IStadiumRepository stadiumRepository,
                            IAzureBlobService azureBlobService)
 {
     _gameRepository     = gameRepository;
     _teamRepository     = teamRepository;
     _gameTeamRepository = gameTeamRepository;
     _stadiumRepository  = stadiumRepository;
     _azureBlobService   = azureBlobService;
 }
 public HomeController(IStadiumRepository stadiumRepo, IMatchRepository matchRepo,
                       IScheduleService scheduleService, IReservationService reservationService,
                       IPriceCalculationStrategy priceCalculationStrategy, ITicketService ticketService,
                       ITicketRepository ticketRepo, IReservationRepository reservationRepo)
 {
     _stadiumRepo              = stadiumRepo;
     _matchRepo                = matchRepo;
     _scheduleService          = scheduleService;
     _reservationService       = reservationService;
     _priceCalculationStrategy = priceCalculationStrategy;
     _ticketService            = ticketService;
     _ticketRepo               = ticketRepo;
     _reservationRepo          = reservationRepo;
 }
Exemple #7
0
        public async Task ReturnAllStadiumsWhichExistsInDb()
        {
            // Arrange
            _stadiumRepository = SoccerStatisticsContextMocker.GetInMemoryStadiumRepository("GetAllStadiums");

            IEnumerable <Stadium> expectedStadiums = new List <Stadium>
            {
                new Stadium
                {
                    Id            = 1,
                    Name          = "Old Trafford",
                    Country       = "England",
                    City          = "Manchester",
                    BuiltAt       = 1910,
                    Capacity      = 75_797,
                    FieldSize     = "105:68",
                    VipCapacity   = 4000,
                    IsForDisabled = true,
                    Lighting      = 100_000,
                    Architect     = "Archibald Leitch",
                    IsNational    = false
                },
 public UserService(IUserRepository userRepository, ITeamService teamService, IStadiumRepository stadiumRepository)
 {
     _userRepository = userRepository;
     _teamService = teamService;
     _stadiumRepository = stadiumRepository;
 }
Exemple #9
0
 public StadiumService(IUnitOfWork unitOfWork,
                       IStadiumRepository stadiumRepository)
 {
     _unitOfWork        = unitOfWork;
     _stadiumRepository = stadiumRepository;
 }
Exemple #10
0
 public HomeController(IStadiumRepository repo)
 {
     this.repo = repo;
 }
 public GetStadiumByIdQueryHandler(IStadiumRepository StadiumRepository, IMapper mapper, ILogger <GetStadiumByIdQueryHandler> logger)
     : base(logger)
 {
     _StadiumRepository = StadiumRepository;
     _mapper            = mapper;
 }
Exemple #12
0
 public UpdateStadiumCommandHandler(IStadiumRepository stadiumRepository, IMapper mapper, ILogger <UpdateStadiumCommandHandler> logger)
     : base(logger)
 {
     _mapper            = mapper;
     _stadiumRepository = stadiumRepository;
 }
Exemple #13
0
 public StadiumService(IStadiumRepository repository)
 {
     _repository = repository;
 }
 public DefaultPriceCalculationStrategy(IMatchRepository matchRepository, IStadiumRepository stadiumRepository)
 {
     _matchRepository   = matchRepository;
     _stadiumRepository = stadiumRepository;
 }
 public StadiumService(IStadiumRepository stadiumRepository, IMapper mapper)
 {
     _stadiumRepository = stadiumRepository;
     _mapper            = mapper;
 }
 public StadiumProcessor()
 {
     _stadiumRepository = new StadiumRepository();
 }
Exemple #17
0
 public HomeController(IStadiumRepository repo)
 {
     this.repo = repo;
     key       = System.IO.File.ReadAllText("../RoadtripApp/googleKey.txt");
 }
 public StadiumService(IStadiumRepository stadiumRepository)
 {
     _stadiumRepository = stadiumRepository;
 }