Pārlūkot izejas kodu

fix historic prices not including current day

Daniel Sheffield 3 gadi atpakaļ
vecāks
revīzija
8d4bb9fb9b
1 mainītis faili ar 1 papildinājumiem un 1 dzēšanām
  1. 1 1
      app/price_view.py

+ 1 - 1
app/price_view.py

@@ -29,7 +29,7 @@ def get_where(product, unit, organic=None, limit='90 days'):
             Literal(organic),
         ]))
     where.append(
-        SQL("{ts} at time zone 'utc' BETWEEN now()::date - {interval} AND now()::date").format(
+        SQL("{ts} at time zone 'utc' BETWEEN now() - {interval} AND now()").format(
             ts=Identifier('ts'),
             interval=SQL("{literal}::interval").format(literal=Literal(limit))
         )