adding automatic charting
This commit is contained in:
@@ -245,6 +245,7 @@ def rower_favoritecharts_view(request,userid=0):
|
||||
r.fastpaceerg = staticchartform.cleaned_data.get('fastpaceerg')
|
||||
r.slowpaceotw = staticchartform.cleaned_data.get('slowpaceotw')
|
||||
r.fastpaceotw = staticchartform.cleaned_data.get('fastpaceotw')
|
||||
r.staticchartonupload = staticchartform.cleaned_data.get('staticchartonupload')
|
||||
r.save()
|
||||
|
||||
if request.method == 'POST' and 'form-TOTAL_FORMS' in request.POST:
|
||||
|
||||
@@ -4793,6 +4793,9 @@ def workout_upload_api(request):
|
||||
|
||||
if make_plot:
|
||||
res, jobid = uploads.make_plot(r,w,f1,f2,plottype,t)
|
||||
elif r.staticchartonupload != 'None':
|
||||
plottype = r.staticchartonupload
|
||||
res, jobid = uploads.make_plot(r,w,f1,f2,plottype,t)
|
||||
|
||||
uploads.do_sync(w,post_data,quick=True)
|
||||
|
||||
@@ -5101,6 +5104,9 @@ def workout_upload_view(request,
|
||||
request.session['async_tasks'] += [(jobid,'make_plot')]
|
||||
except KeyError:
|
||||
request.session['async_tasks'] = [(jobid,'make_plot')]
|
||||
elif r.staticchartonupload != None:
|
||||
plottype = r.staticchartonupload
|
||||
res, jobid = uploads.make_plot(r,w,f1,f2,plottype,t)
|
||||
|
||||
# upload to C2
|
||||
if (upload_to_c2):
|
||||
|
||||
Reference in New Issue
Block a user