コード例 #1
0
 public TimelinesController(ITimelineService _timelineService, IRefereeService _refereeService,
                            IGeneralUnitService _generalUnitService, ITournamentService _tournamentService)
 {
     timelineService    = _timelineService;
     refereeService     = _refereeService;
     generalUnitService = _generalUnitService;
     tournamentService  = _tournamentService;
 }
コード例 #2
0
 public refereeController(IMailService mailService, IMemberService memberService, IRefereeService refereeService, IRefereeSignUpService refereeSignUpService, IMemberTempService memberTempService, IEventService eventService, IEventSignService eventSignService)
 {
     _memberService        = memberService;
     _refereeService       = refereeService;
     _refereeSignUpService = refereeSignUpService;
     _memberTempService    = memberTempService;
     _eventService         = eventService;
     _eventSignService     = eventSignService;
     _mailService          = mailService;
 }
コード例 #3
0
 public LoginFormViewModel(IRegionManager regionManager, IInteractionService interactionService, IRefereeService refereeService)
 {
     this.regionManager       = regionManager;
     this.interactionService  = interactionService;
     this.refereeService      = refereeService;
     this.NavigateAwayCommand = new DelegateCommand(() =>
     {
         regionManager.RequestNavigate(UiRegions.MainRegion, nameof(MainMenu));
     });
 }
コード例 #4
0
 public RefereeController(ILogger <RefereeController> logger,
                          IRefereeService refereeService,
                          IValidator <Referee> validator,
                          IMapper mapper)
 {
     this.logger         = logger;
     this.refereeService = refereeService;
     this.validator      = validator;
     this.mapper         = mapper;
 }
コード例 #5
0
        //private string username;

        public MainMenuViewModel(IRegionManager regionManager, IRefereeService service, IInteractionService interaction)
        {
            this.regionManager         = regionManager;
            this.service               = service;
            this.interaction           = interaction;
            this.ChangePasswordCommand = new DelegateCommand(() =>
                                                             regionManager.RequestNavigate(UiRegions.MainRegion, nameof(ChangePasswordForm)));
            this.ChooseMatchCommand = new DelegateCommand(() =>
                                                          regionManager.RequestNavigate(UiRegions.MainRegion, nameof(MatchListForm)));
            this.GetPlayer = new DelegateCommand(() => this.interaction.ShowMessageBox("title", (this.service.GetPlayer()).FirstName));
        }
コード例 #6
0
 public MatchController(
     IMatchService matchService,
     IClubService clubService,
     ISeasonService seasonService,
     IStadiumService stadiumService,
     IRefereeService refereeService)
 {
     this.matchService   = matchService;
     this.clubService    = clubService;
     this.seasonService  = seasonService;
     this.stadiumService = stadiumService;
     this.refereeService = refereeService;
 }
コード例 #7
0
 public RefereesController(IRefereeService _refereeService,
                           ITournamentService _tournamentService,
                           ISportUnitService _sportUnitService,
                           IFightService _fightService,
                           IFighterService _fighterService,
                           INavigationService _navigationService)
 {
     tournamentService = _tournamentService;
     refereeService    = _refereeService;
     sportUnitService  = _sportUnitService;
     fightService      = _fightService;
     fighterService    = _fighterService;
     navigationService = _navigationService;
 }
コード例 #8
0
 public FixturesController(ICompetitionService competitionService,
                           IFixtureService fixtureService,
                           ITeamService teamService,
                           IRefereeService refereeService,
                           IMembershipService membershipService,
                           ICupService cupService,
                           IOneOffVenueService oneOffVenueService)
 {
     this.competitionService = competitionService;
     this.fixtureService     = fixtureService;
     this.teamService        = teamService;
     this.refereeService     = refereeService;
     this.membershipService  = membershipService;
     this.cupService         = cupService;
     this.oneOffVenueService = oneOffVenueService;
 }
コード例 #9
0
 public MatchController(ILogger <MatchController> logger,
                        IMatchService matchService,
                        IPlayerService playerService,
                        IManagerService managerService,
                        IRefereeService refereeService,
                        IValidator <Match> validator,
                        IMapper mapper)
 {
     this.logger         = logger;
     this.matchService   = matchService;
     this.playerService  = playerService;
     this.managerService = managerService;
     this.refereeService = refereeService;
     this.validator      = validator;
     this.mapper         = mapper;
 }
コード例 #10
0
 public FixturesController(ICompetitionService competitionService,
     IFixtureService fixtureService,
     ITeamService teamService,
     IRefereeService refereeService,
     IMembershipService membershipService,
     ICupService cupService,
     IOneOffVenueService oneOffVenueService)
 {
     this.competitionService = competitionService;
     this.fixtureService     = fixtureService;
     this.teamService        = teamService;
     this.refereeService     = refereeService;
     this.membershipService  = membershipService;
     this.cupService         = cupService;
     this.oneOffVenueService    = oneOffVenueService;
 }
コード例 #11
0
 public void TestInitialize()
 {
     this.leagueService         = new Mock <IRefereeLeagueService>();
     this.authenticationService = new Mock <IAuthenticationService>();
     this.refService            = new RefereeServiceLibrary.RefereeService(leagueService.Object, authenticationService.Object);
 }
コード例 #12
0
 public RefereeController(IRefereeService refereeService, ICountryService countryService)
 {
     this.refereeService = refereeService;
     this.countryService = countryService;
 }
コード例 #13
0
 public RefereeDataController(IRefereeService refereeService)
 {
     _refereeService = refereeService;
 }
コード例 #14
0
 public RefereesController(IRefereeService refereeService)
 {
     Check.Require(refereeService != null, "refereeService may not be null");
     this.refereeService = refereeService;
 }
 public ChangePasswordFormViewModel(IRegionManager regionManager, IInteractionService interactionService, IRefereeService refereeService)
 {
     this.regionManager      = regionManager;
     this.interactionService = interactionService;
     this.refereeService     = refereeService;
 }
コード例 #16
0
 public RefereesController(IRefereeService refereeService)
 {
     Check.Require(refereeService != null, "refereeService may not be null");
     this.refereeService = refereeService;
 }
コード例 #17
0
        public EditMatchFormViewModel(IRegionManager regionManager, IRefereeService refereeService, IInteractionService interactionService, IGeocodingService geocodingService)
        {
            CalculateRouteCommand = new MyDelegateCommand(CalculateRoute);

            this.regionManager      = regionManager;
            this.refereeService     = refereeService;
            this.interactionService = interactionService;
            this.geocodingService   = geocodingService;

            AddGoalCommand = new DelegateCommand(() =>
            {
                var teamId = Match.HomeTeamPlayers.Contains(SelectedPlayer) ? (SelectedType == GoalType.Own ? Match.AwayTeamId : Match.HomeTeamId) :
                             (SelectedType == GoalType.Own ? Match.HomeTeamId : Match.AwayTeamId);
                var goal = new GoalDTO()
                {
                    Scorer   = SelectedPlayer,
                    GoalType = SelectedType,
                    TeamId   = teamId,
                    Time     = Time
                };
                if (teamId == Match.HomeTeamId)
                {
                    HomeGoals.Add(goal);
                    var ordered = this.HomeGoals.OrderBy(x => x.Time).ToList();
                    this.HomeGoals.Clear();
                    this.HomeGoals.AddRange(ordered);
                    Match.HomeTeamScore = (Match.HomeTeamScore ?? 0) + 1;
                }
                else
                {
                    AwayGoals.Add(goal);
                    var ordered = this.AwayGoals.OrderBy(x => x.Time).ToList();
                    this.AwayGoals.Clear();
                    this.AwayGoals.AddRange(ordered);
                    Match.AwayTeamScore = (Match.AwayTeamScore ?? 0) + 1;
                }
                this.interactionService.ShowMessageBox("Success", "Goal was added successfully");
            });

            RemoveGoalCommand = new DelegateCommand <GoalDTO>((goal) =>
            {
                if (HomeGoals.Contains(goal))
                {
                    HomeGoals.Remove(goal);
                    Match.HomeTeamScore--;
                }
                else
                {
                    AwayGoals.Remove(goal);
                    Match.AwayTeamScore--;
                }
            });

            OkCommand = new DelegateCommand(async() =>
            {
                if (IsEditing)
                {
                    IsEnabled           = true;
                    Match.HomeTeamGoals = HomeGoals.ToArray();
                    Match.AwayTeamGoals = AwayGoals.ToArray();
                    if (Match.HomeTeamScore == null)
                    {
                        Match.HomeTeamScore = 0;
                    }
                    if (Match.AwayTeamScore == null)
                    {
                        Match.AwayTeamScore = 0;
                    }
                    await this.refereeService.SaveGoalsAsync(Match);
                    IsEnabled = false;
                }
                GlobalCommands.GoBackCommand.Execute(null);
            });
        }
コード例 #18
0
 public MatchListFormViewModel(IRegionManager regionManager, IRefereeService refereeService, IViewToDataService viewToDataService)
 {
     this.regionManager     = regionManager;
     this.refereeService    = refereeService;
     this.viewToDataService = viewToDataService;
 }
コード例 #19
0
 public RefereeDataController(IRefereeService refereeService)
 {
     _refereeService = refereeService;
 }
コード例 #20
0
 public EngineService(IReadService readService, IWriteService writeService, IRefereeService refereeService)
 {
     _readService    = readService;
     _writeService   = writeService;
     _refereeService = refereeService;
 }