fix error with points

sync_v2
Razmig Sarkissian 5 months ago
parent 396735e70c
commit af83311c9d
  1. 8
      tournaments/services/tournament_registration.py

@ -418,6 +418,12 @@ class RegistrationCartManager:
except ValueError:
tournament_played = None
points = player_data.get('points')
try:
points = float(points)
except ValueError:
points = None
# Create player registration with all the original fields
PlayerRegistration.objects.create(
team_registration=team_registration,
@ -427,7 +433,7 @@ class RegistrationCartManager:
registered_online=True,
first_name=player_data.get('first_name'),
last_name=player_data.get('last_name'),
points=player_data.get('points'),
points=points,
assimilation=player_data.get('assimilation'),
tournament_played=tournament_played,
ligue_name=player_data.get('ligue_name'),

Loading…
Cancel
Save