public void SetMatch(Date date, Time time, Team homeTeam, Team awayTeam, League league, MatchResult matchResult, FullOdd fullOdd, int matchCode) { this.MatchCode = matchCode; this.Date = date; this.DateId = date.DateId; date.Matches.Add(this); this.Time = time; this.TimeId = TimeId; time.Matches.Add(this); this.HomeTeam = homeTeam; this.HomeTeamId = homeTeam.TeamId; homeTeam.HomeMatches.Add(this); this.AwayTeam = awayTeam; this.AwayTeamId = AwayTeamId; awayTeam.AwayMatches.Add(this); this.League = league; this.LeagueId = league.LeagueId; league.Matches.Add(this); this.MatchResult = matchResult; this.MatchResultId = matchResult.MatchResultId; matchResult.Matches.Add(this); this.FullOdd = fullOdd; this.FullOddId = fullOdd.FullOddId; fullOdd.Matches.Add(this); this.HomeTeamName = homeTeam.TeamName; this.AwayTeamName = awayTeam.TeamName; this.FhScore = matchResult.FirstHalfHomeScore + " - " + matchResult.FirstHalfAwayScore; this.MsScore = matchResult.MatchHomeScore + " - " + matchResult.MatchAwayScore; }
public void SetFullOdd(FullOdd fullOdd) { this.FullOdd = fullOdd; this.FullOddId = fullOdd.FullOddId; fullOdd.Matches.Add(this); }