Merge branch 'release/v5.91'
This commit is contained in:
@@ -196,11 +196,16 @@ def is_session_complete_ws(ws,ps):
|
|||||||
if ratio == 1.0:
|
if ratio == 1.0:
|
||||||
return ratio,'completed',completiondate
|
return ratio,'completed',completiondate
|
||||||
else:
|
else:
|
||||||
|
if not completiondate:
|
||||||
|
completiondate = ws.reverse()[0].date
|
||||||
return ratio,'partial',completiondate
|
return ratio,'partial',completiondate
|
||||||
elif ps.criterium == 'minimum':
|
elif ps.criterium == 'minimum':
|
||||||
if ratio >= 1.0:
|
if ratio >= 1.0:
|
||||||
return ratio,'completed',completiondate
|
return ratio,'completed',completiondate
|
||||||
else:
|
else:
|
||||||
|
if not completiondate:
|
||||||
|
completiondate = ws.reverse()[0].date
|
||||||
|
|
||||||
return ratio,'partial',completiondate
|
return ratio,'partial',completiondate
|
||||||
else:
|
else:
|
||||||
if ratio>cratiomin and ratio<cratiomax:
|
if ratio>cratiomin and ratio<cratiomax:
|
||||||
@@ -222,11 +227,17 @@ def is_session_complete_ws(ws,ps):
|
|||||||
if ratio > 1.0:
|
if ratio > 1.0:
|
||||||
return ratio,'completed',completiondate
|
return ratio,'completed',completiondate
|
||||||
else:
|
else:
|
||||||
|
if not completiondate:
|
||||||
|
completiondate = ws.reverse()[0].date
|
||||||
return ratio,'partial',completiondate
|
return ratio,'partial',completiondate
|
||||||
else:
|
else:
|
||||||
|
if not completiondate:
|
||||||
|
completiondate = ws.reverse()[0].date
|
||||||
return ratio,'partial',completiondate
|
return ratio,'partial',completiondate
|
||||||
|
|
||||||
else:
|
else:
|
||||||
|
if not completiondate:
|
||||||
|
completiondate = ws.reverse()[0].date
|
||||||
return ratio,status,completiondate
|
return ratio,status,completiondate
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -268,6 +268,8 @@ def createstravaworkoutdata(w,dozip=True):
|
|||||||
row = rowingdata(filename)
|
row = rowingdata(filename)
|
||||||
except IOError:
|
except IOError:
|
||||||
return '','Error - could not find rowing data'
|
return '','Error - could not find rowing data'
|
||||||
|
else:
|
||||||
|
return '','Error - could not find rowing data'
|
||||||
|
|
||||||
tcxfilename = filename[:-4]+'.tcx'
|
tcxfilename = filename[:-4]+'.tcx'
|
||||||
try:
|
try:
|
||||||
|
|||||||
@@ -12354,7 +12354,6 @@ def plannedsession_clone_view(request,id=0,rowerid=0,
|
|||||||
'id':ps.id,
|
'id':ps.id,
|
||||||
'timeperiod':timeperiod,
|
'timeperiod':timeperiod,
|
||||||
'rowerid':r.id,
|
'rowerid':r.id,
|
||||||
'rower':r,
|
|
||||||
}
|
}
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user