|
|
|
@ -1398,6 +1398,19 @@ class Tournament(BaseModel): |
|
|
|
|
|
|
|
|
|
|
|
return serializable_match_groups |
|
|
|
return serializable_match_groups |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
def has_bracket(self): |
|
|
|
|
|
|
|
main_rounds = self.round_set.filter( |
|
|
|
|
|
|
|
parent=None, |
|
|
|
|
|
|
|
group_stage_loser_bracket=False |
|
|
|
|
|
|
|
) |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
count = main_rounds.count() |
|
|
|
|
|
|
|
if count == 0: |
|
|
|
|
|
|
|
return False |
|
|
|
|
|
|
|
else: |
|
|
|
|
|
|
|
return True |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
class MatchGroup: |
|
|
|
class MatchGroup: |
|
|
|
def __init__(self, name, matches, formatted_schedule, round_id=None): |
|
|
|
def __init__(self, name, matches, formatted_schedule, round_id=None): |
|
|
|
self.name = name |
|
|
|
self.name = name |
|
|
|
|