More work InfluxDB templated queries and required changes to editor and datasource
More progress on influxdb query editor, templating, refactoring, unit tests, #740, #507, #586