1
0
mirror of https://github.com/jcwimer/wrestlingApp synced 2026-03-25 01:14:43 +00:00

Merge branch 'development'

This commit is contained in:
2018-01-31 07:39:04 -05:00

View File

@@ -43,7 +43,7 @@ class GenerateTournamentMatches
def assignBouts
bout_counts = Hash.new(0)
@tournament.matches.each do |m|
@tournament.matches.sort_by{|m| [m.round, m.weight_max]}.each do |m|
m.bout_number = m.round * 1000 + bout_counts[m.round]
bout_counts[m.round] += 1
m.save!