1
0
mirror of https://github.com/jcwimer/wrestlingApp synced 2026-04-03 05:27:25 +00:00

Added bye points for double elimination and modified double elimination

This commit is contained in:
2021-12-20 20:48:29 +00:00
parent 8430949a37
commit 54e755ba3a
4 changed files with 144 additions and 5 deletions

View File

@@ -145,6 +145,14 @@ class Wrestler < ActiveRecord::Base
matches_won.select{|m| (m.bracket_position == "Conso Semis" or m.bracket_position == "Conso" or m.bracket_position == "Conso Quarter") and m.win_type != "BYE"}
end
def championship_byes
matches_won.select{|m| (m.bracket_position == "Quarter" or m.bracket_position == "Semis" or m.bracket_position == "Bracket") and m.win_type == "BYE"}
end
def consolation_byes
matches_won.select{|m| (m.bracket_position == "Conso Semis" or m.bracket_position == "Conso" or m.bracket_position == "Conso Quarter") and m.win_type == "BYE"}
end
def finished_matches
all_matches.select{|m| m.finished == 1}
end