Skip to content
Snippets Groups Projects
Commit f9eec97c authored by Nicolas Martinelli's avatar Nicolas Martinelli
Browse files

[FIX] web: date warning


- Set the computer TZ so that it is UTC day + 1. For example, set to
  'Australia/Adelaide' and perform the tests after 3:00 pm
- Go to Account > Customers > Invoices
- Set the Invice Date to today in the TZ

You receive the warning 'This date is on the future...'

The comparison of a UTC date without time `currentDate` is inconsistent
with `moment()`, which is not UTC and has a time set.

After playing around with `.utc()` and `startOf('d')` with no luck, we
decided to give up the idea of making `getTZOffset()` enter the game and
simply compare the string formatted values.

opw-2093186

closes odoo/odoo#40950

Signed-off-by: default avatarNicolas Martinelli (nim) <nim@odoo.com>
parent 40d3fa50
No related branches found
No related tags found
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment