Promote single-line comments
This commit is contained in:
parent
f2dcb718c7
commit
05601e0adb
@ -179,9 +179,9 @@
|
||||
group = group.values.reduce(((acc, x) => ((acc.values[x.name] || (acc.values[x.name] = [])).push(x), acc)), { key: group.key, datehdr: date_header(group.key), values: {}});
|
||||
for(var k in group.values) if(group.values.hasOwnProperty(k)) {
|
||||
var items = group.values[k].sort((a, b) => a.time - b.time);
|
||||
var strings = items.map(item => item.time.toLocaleTimeString('en-GB') + ' • ' + item.value + (item.unit ? ' ' + item.unit : '') + (item.flag ? ' [' + item.flag + ']' : ''));
|
||||
var strings = items.map(item => item.time.toLocaleTimeString('en-GB') + ' • ' + item.value + (item.unit ? ' ' + item.unit : '') + (item.flag ? ' [' + item.flag + ']' : '') + (item.comment && item.comment.indexOf('\n') < 0 ? ' • ' + item.comment : ''));
|
||||
var flags = uniq(items.map(item => item.flag).filter(x => x).map(x => x.charAt(0)));
|
||||
var comments = uniq(items.map(item => item.comment).filter(x => x));
|
||||
var comments = uniq(items.map(item => item.comment).filter(x => x && x.indexOf('\n') >= 0));
|
||||
var numbers = uniq(items.map(item => item.value).filter(x => isNumeric(x)));
|
||||
var min = Math.min.apply(null, numbers);
|
||||
var max = Math.max.apply(null, numbers);
|
||||
|
Loading…
Reference in New Issue
Block a user