summaryrefslogtreecommitdiff
path: root/app/static/js/chart.js
diff options
context:
space:
mode:
Diffstat (limited to 'app/static/js/chart.js')
-rw-r--r--app/static/js/chart.js9
1 files changed, 5 insertions, 4 deletions
diff --git a/app/static/js/chart.js b/app/static/js/chart.js
index d72d415..06edc4d 100644
--- a/app/static/js/chart.js
+++ b/app/static/js/chart.js
@@ -1,7 +1,6 @@
-
-function fillChart(id) {
- const ctx = document.getElementById(id)
- new Chart(document.getElementById('exercise_chart'), {
+function exercise_chart(elem_id, exercise_id) {
+ // Create initial chart
+ let chart = new Chart(document.getElementById(elem_id), {
type: 'line',
data: {
cubicInterpolationMode: 'monotone',
@@ -18,4 +17,6 @@ function fillChart(id) {
}
}
});
+
+ // Load chart data for exercise
}