Commit dbc1a9cf by Torkel Ödegaard

fix(influxdb_0.8.x): fixed issue with new timepicker ranges like The day so far, fixes #2936

parent c95a991c
......@@ -266,11 +266,11 @@ function (angular, _, dateMath, InfluxSeries, InfluxQueryBuilder) {
}
function getInfluxTime(date, roundUp) {
if (_.isString(date) && date.indexOf('/') === -1) {
if (_.isString(date)) {
if (date === 'now') {
return 'now()';
}
if (date.indexOf('now-') >= 0) {
if (date.indexOf('now-') >= 0 && date.indexOf('/') === -1) {
return date.replace('now', 'now()');
}
date = dateMath.parse(date, roundUp);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment