support passing functions to the backend as parameters

This commit is contained in:
azivner
2018-02-18 09:53:36 -05:00
parent 08bc2afb49
commit ddc885066e
3 changed files with 20 additions and 7 deletions

View File

@@ -117,16 +117,11 @@
return data;
});
const colors = data.map(row => row.comment ? 'darkred' : 'red');
const datasets = [{
label: "Weight",
backgroundColor: 'red',
borderColor: 'red',
data: data.map(row => row.weight),
// this is to emphasize points with color
pointBackgroundColor: colors,
pointBorderColor: colors,
fill: false
}];