diff --git a/config/settings.py b/config/settings.py index 80534cac0b..4c796c8ce4 100644 --- a/config/settings.py +++ b/config/settings.py @@ -11,8 +11,16 @@ https://docs.djangoproject.com/en/3.2/ref/settings/ """ import os -from pathlib import Path import environ +# import sentry_sdk +from pathlib import Path +# from sentry_sdk.integrations.django import DjangoIntegration + +# Sentry +# sentry_sdk.init( +# dsn=os.environ['SENTRY_DSN'], +# integrations=[DjangoIntegration()] +# ) # Initialise environment variables env = environ.Env() diff --git a/templates/people/gymnasts/create.html b/templates/people/gymnasts/create.html index 0a9f224f70..c081dab4b0 100644 --- a/templates/people/gymnasts/create.html +++ b/templates/people/gymnasts/create.html @@ -8,7 +8,7 @@

{% if gymnast_id %}Edit{% else %}Add{% endif %} Gymnast

-
+ {% csrf_token %}
@@ -106,6 +106,16 @@ }); blackDashboard.initDateTimePicker(); + $('#id_hours_by_week').focusout(function(){ + value = $(this).val().replace(/,/g, '.'); + $(this).val(parseFloat(value).toFixed(1)); + }); + + $('#form').submit(function(){ + $('#id_hours_by_week').val().replace(/,/g, '.'); + $('#id_hours_by_week').val(parseFloat(value).toFixed(1)); + }) + $('#id_club_related').autocomplete({ source: function(request, response) { $.ajax({