Private
Public Access
1
0
This commit is contained in:
2025-01-20 21:21:11 +01:00
parent 10b1273adf
commit fc925e199f
3 changed files with 22 additions and 10 deletions

View File

@@ -15,7 +15,7 @@ from rowingdata import rowingdata
from rowers.rower_rules import is_workout_user
import time
from django_rq import job
from rowers.mytypes import tpmapping
from rowers.mytypes import tpmapping, tcxmapping
from rowers.tasks import check_tp_workout_id, handle_workout_tp_upload
@@ -68,7 +68,8 @@ class TPIntegration(SyncIntegration):
newnotes = 'from '+w.workoutsource+' via rowsandall.com'
try:
row.exporttotcx(tcxfilename, notes=newnotes, sport=tpmapping[w.workouttype])
#row.exporttotcx(tcxfilename, notes=newnotes, sport=tcxmapping[w.workouttype])
row.exporttotcx(tcxfilename, notes=newnotes, sport=None)
except KeyError:
row.exporttotcx(tcxfilename, notes=newnotes, sport='other')
@@ -83,7 +84,8 @@ class TPIntegration(SyncIntegration):
handle_workout_tp_upload,
workout,
thetoken,
tcxfilename
tcxfilename,
tpmapping[workout.workouttype]
)
return job.id