|
|
|
|
@ -37,10 +37,11 @@ def init_store_id(apps, schema_editor): |
|
|
|
|
if instance.team_registration: |
|
|
|
|
id = instance.team_registration.tournament.id |
|
|
|
|
else: |
|
|
|
|
if instance.match.round: |
|
|
|
|
id = instance.round.tournament.id |
|
|
|
|
match = instance.match |
|
|
|
|
if match.round: |
|
|
|
|
id = match.round.tournament.id |
|
|
|
|
else: |
|
|
|
|
id = instance.group_stage.tournament.id |
|
|
|
|
id = match.group_stage.tournament.id |
|
|
|
|
instance.store_id = str(id) |
|
|
|
|
instance.save() |
|
|
|
|
|
|
|
|
|
|