Skip to content

[MDS-5056] UTC Validation for TSF EOR/QP #2681

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Sep 19, 2023
Merged

[MDS-5056] UTC Validation for TSF EOR/QP #2681

merged 1 commit into from
Sep 19, 2023

Conversation

taraepp
Copy link
Collaborator

@taraepp taraepp commented Sep 19, 2023

Objective

  • fix the validation, odd things happening with timezones
  • the input gets passed into validation like "2023-09-19"
  • OLD: new Date("2023-09-19") returns Mon Sep 18 2023 18:00:00 GMT-0600, and this is what was being compared to the current date/time to test if it's in the future.
  • NEW: moment("2023-09-19") returns Tue Sep 19 2023 00:00:00 GMT-0600- this is what I have changed it to, so it will be midnight of that day in the user's local timezone instead of UTC.
  • only validation is being changed, data being saved is the same (saved in format 2023-09-19).

MDS-5056

switched compare function to moment from native Date so that 2023-02-15 does not become 2023-02-14 at 6pm local time
@taraepp taraepp added 🐞 Bug Something isn't working :( 💻 Frontend This pull request includes frontend changes. labels Sep 19, 2023
Copy link
Collaborator

@matbusby-fw matbusby-fw left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🕛

@taraepp taraepp merged commit 00fb175 into develop Sep 19, 2023
@taraepp taraepp deleted the mds-5056 branch September 19, 2023 21:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🐞 Bug Something isn't working :( 💻 Frontend This pull request includes frontend changes.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants