Private
Public Access
1
0

does Alternative OTE ranking

added an OTE ranking piece calculator based on manually added ranking
instead of automatically detected ranking
This commit is contained in:
Sander Roosendaal
2017-10-26 22:53:02 +02:00
parent 0f5c49de62
commit 29243516ae
8 changed files with 295 additions and 18 deletions

View File

@@ -420,7 +420,7 @@ def handle_updateergcp(rower_id,workoutfilenames,debug=False):
@app.task
def handle_updatecp(rower_id,workoutids,debug=False):
def handle_updatecp(rower_id,workoutids,debug=False,table='cpdata'):
columns = ['power','workoutid','time']
df = getsmallrowdata_db(columns,ids=workoutids,debug=debug)
dfgrouped = df.groupby(['workoutid'])
@@ -435,7 +435,7 @@ def handle_updatecp(rower_id,workoutids,debug=False):
delta,cpvalue,avgpower = datautils.getcp(dfgrouped,logarr)
updatecpdata_sql(rower_id,delta,cpvalue,debug=debug)
updatecpdata_sql(rower_id,delta,cpvalue,debug=debug,table=table)
return 1