Finish query builder for LIMIT, SLIMIT and ORDER BY time #6065

This commit is contained in:
thuck 2017-03-05 23:41:16 +01:00
parent f577dd0f38
commit c3eb9da160

View File

@ -250,6 +250,18 @@ export default class InfluxQuery {
query += ' fill(' + target.fill + ')'; query += ' fill(' + target.fill + ')';
} }
if (target.orderByTime === 'DESC') {
query += ' ORDER BY time DESC';
}
if (target.limit) {
query += ' LIMIT ' + target.limit;
}
if (target.slimit) {
query += ' SLIMIT ' + target.slimit;
}
return query; return query;
} }