Remove fmbit js function.

The value_js_formatter is now used to format the measurement value in the datatable
This commit is contained in:
emanuele-f 2020-04-16 10:55:43 +02:00
parent 1e5376da95
commit aa2ad9c66e
10 changed files with 15 additions and 13 deletions

View file

@ -274,7 +274,10 @@ $(document).ready(function() {
data: 'last_measure',
className: 'dt-body-right dt-head-center',
render: function(data, type, row) {
if(row.last_measure)
if(row.value_js_formatter && row.last_measure)
// Call the provided formatting function
return window[row.value_js_formatter](row.last_measure);
else if(row.last_measure)
return `${row.last_measure} ${row.unit}`
else
return "";