Merge branch 'release/v6.90'
This commit is contained in:
@@ -531,7 +531,7 @@ class TrendFlexModalForm(forms.Form):
|
||||
class StatsOptionsForm(forms.Form):
|
||||
includereststrokes = forms.BooleanField(initial=False,label='Include Rest Strokes',required=False)
|
||||
rankingonly = forms.BooleanField(initial=False,
|
||||
label='Only Ranking Pieces',required=True)
|
||||
label='Only Ranking Pieces',required=False)
|
||||
water = forms.BooleanField(initial=False,required=False)
|
||||
waterboattype = forms.MultipleChoiceField(choices=boattypes,
|
||||
label='Water Boat Type',
|
||||
|
||||
@@ -3012,6 +3012,7 @@ def cum_flex_data(
|
||||
startdatestring = def_options['startdatestring']
|
||||
enddatestring = def_options['enddatestring']
|
||||
deltadays = def_options['deltadays']
|
||||
request.session['options'] = def_options
|
||||
|
||||
|
||||
|
||||
@@ -3268,6 +3269,7 @@ def cum_flex(request,theuser=0,
|
||||
options['workouttypes'] =workouttypes
|
||||
options['waterboattype'] =waterboattype
|
||||
options['theuser'] =theuser
|
||||
options['rankingonly'] = rankingonly
|
||||
options['xparam'] =xparam
|
||||
options['yparam1'] =yparam1
|
||||
options['yparam2'] =yparam2
|
||||
@@ -5868,7 +5870,8 @@ def user_multiflex_select(request,
|
||||
|
||||
modalityform = TrendFlexModalForm(initial={
|
||||
'modality':modality,
|
||||
'waterboattype':waterboattype
|
||||
'waterboattype':waterboattype,
|
||||
'rankingonly':rankingonly,
|
||||
})
|
||||
|
||||
messages.info(request,successmessage)
|
||||
@@ -5879,6 +5882,11 @@ def user_multiflex_select(request,
|
||||
request.session['startdate'] = startdatestring
|
||||
request.session['enddate'] = enddatestring
|
||||
|
||||
request.session['waterboattype'] = waterboattype
|
||||
request.session['rankingonly'] = rankingonly
|
||||
request.session['modalities'] = modalities
|
||||
|
||||
|
||||
return render(request, 'user_multiflex_select.html',
|
||||
{'workouts': workouts,
|
||||
'dateform':dateform,
|
||||
@@ -6351,12 +6359,14 @@ def user_boxplot_select(request,
|
||||
for type in types.checktypes:
|
||||
if optionsform.cleaned_data[type]:
|
||||
workouttypes.append(type)
|
||||
|
||||
|
||||
options = {
|
||||
'workouttypes':workouttypes,
|
||||
'waterboattype':waterboattype,
|
||||
'rankingonly':rankingonly,
|
||||
}
|
||||
|
||||
|
||||
request.session['options'] = options
|
||||
|
||||
|
||||
@@ -6432,6 +6442,7 @@ def user_boxplot_select(request,
|
||||
# set options form correctly
|
||||
initial = {}
|
||||
initial['waterboattype'] = waterboattype
|
||||
initial['rankingonly'] = rankingonly
|
||||
|
||||
for wtype in types.checktypes:
|
||||
if wtype in workouttypes:
|
||||
@@ -6439,6 +6450,7 @@ def user_boxplot_select(request,
|
||||
else:
|
||||
initial[wtype] = False
|
||||
|
||||
|
||||
optionsform = StatsOptionsForm(initial=initial)
|
||||
|
||||
messages.info(request,successmessage)
|
||||
@@ -6562,6 +6574,7 @@ def boxplot_view_data(request,userid=0,
|
||||
def boxplot_view(request,userid=0,
|
||||
options={
|
||||
'includereststrokes':False,
|
||||
'rankingonly':False,
|
||||
}):
|
||||
|
||||
if 'options' in request.session:
|
||||
@@ -6572,6 +6585,12 @@ def boxplot_view(request,userid=0,
|
||||
except KeyError:
|
||||
includereststrokes = False
|
||||
options['includereststrokes'] = False
|
||||
|
||||
try:
|
||||
rankingonly = options['rankingonly']
|
||||
except KeyError:
|
||||
rankingonly = False
|
||||
options['rankingonly'] = False
|
||||
|
||||
workstrokesonly = not includereststrokes
|
||||
|
||||
@@ -6629,6 +6648,7 @@ def boxplot_view(request,userid=0,
|
||||
options['ids'] = ids
|
||||
options['userid'] = userid
|
||||
options['plotfield'] = plotfield
|
||||
options['rankingonly'] = rankingonly
|
||||
|
||||
request.session['options'] = options
|
||||
|
||||
@@ -8042,6 +8062,7 @@ def cumstats(request,theuser=0,
|
||||
initial = {}
|
||||
initial['includereststrokes'] = includereststrokes
|
||||
initial['waterboattype'] = waterboattype
|
||||
initial['rankingonly'] = rankingonly
|
||||
|
||||
for wtype in types.checktypes:
|
||||
if wtype in workouttypes:
|
||||
|
||||
Reference in New Issue
Block a user