Private
Public Access
1
0

bug fix javascript upload

This commit is contained in:
Sander Roosendaal
2017-11-10 13:56:04 +01:00
parent 92e49fe468
commit bb77efb6fc
2 changed files with 21 additions and 9 deletions

View File

@@ -847,11 +847,7 @@ def save_workout_database(f2, r, dosmooth=True, workouttype='rower',
return (w.id, message)
def handle_nonpainsled(f2, fileformat, summary=''):
oarlength = 2.89
inboard = 0.88
hasrecognized = False
def parsenonpainsled(fileformat,f2,summary):
# handle RowPro:
if (fileformat == 'rp'):
row = RowProParser(f2)
@@ -936,6 +932,19 @@ def handle_nonpainsled(f2, fileformat, summary=''):
summary = s.summarytext
except:
pass
hasrecognized = True
return row,hasrecognized,summary
def handle_nonpainsled(f2, fileformat, summary=''):
oarlength = 2.89
inboard = 0.88
hasrecognized = False
try:
row,hasrecognized = parsenonpainsled(fileformat,f2,summary)
except:
pass
# Handle c2log
if (fileformat == 'c2log' or fileformat == 'rowprolog'):

View File

@@ -209,11 +209,14 @@
},
success: function(result) {
console.log('got something back');
console.log(result);
console.log(result);
if (result.result == 1) {
window.location.href = result.url;
}
}
window.location.href = result.url;
} else {
console.log(result," reloading");
location.reload();
};
}
});
return false;
});