コード例 #1
0
        public CompetitionLayoutIndexViewModel(CompetitionInfo info, ScoringMap scoringMap)
        {
            Info = info;
            ScoringMap = scoringMap;

            Performances =
                info
                    .Registrations
                    .SelectMany(x => x.GetPerformances(info.Competition))
                    .ToList();

            var go =
                Performances.Where(x => x.RegistrationId == "company/1/competitions/5/registrations/gyms/41/team/12").ToList();

            JudgePanel = new FiveJudgePanel(new List<JudgeScore>()); //TODO: If we need a different panel....
            SecurityContext = new SecurityContext();
        }
コード例 #2
0
        public CompetitionDataIndexViewModel(Schedule schedule
		                                     , Competition competition
		                                     , IEnumerable<Level> levels
		                                     , IEnumerable<Division> divisions
		                                     , IEnumerable<Gym> gyms
		                                     , IEnumerable<Registration> registrations
		                                     , IEnumerable<Performance> performances
			)
        {
            Schedule = schedule;
            Competition = competition;

            Levels = levels;
            Divisions = divisions;
            Gyms = gyms;
            Registrations = registrations;
            Performances = performances;
            ScoringMap = new ScoringMap();
        }