[FIX] _transient_clean_rows_older_than() WHERE clause

This commit is contained in:
Andrea
2018-09-21 09:18:47 +02:00
committed by chaule97
parent 819dc05de0
commit 243b6d63af
2 changed files with 2 additions and 2 deletions

View File

@@ -15,7 +15,7 @@ class AbstractReport(models.AbstractModel):
query = """
DELETE FROM """ + self._table + """
WHERE COALESCE(
write_date, self.create_date, (now() at time zone 'UTC'))::timestamp
write_date, create_date, (now() at time zone 'UTC'))::timestamp
< ((now() at time zone 'UTC') - interval %s)
"""
self.env.cr.execute(query, ("%s seconds" % seconds,))