Skip to content
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

[HXCS-2818] CardViewDateItem component ignore timezone when displaying dates #9304

Merged
merged 5 commits into from
Feb 5, 2024

Conversation

wideLandscape
Copy link
Contributor

@wideLandscape wideLandscape commented Feb 5, 2024

Please check if the PR fulfills these requirements

  • The commit message follows our guidelines
  • Tests for the changes have been added (for bug fixes / features)
  • Docs have been added / updated (for bug fixes / features)

What kind of change does this PR introduce? (check one with "x")

  • Bugfix
  • Feature
  • Code style update (formatting, local variables)
  • Refactoring (no functional changes, no api changes)
  • Build related changes
  • Documentation
  • Other... Please describe:

What is the current behaviour? (You can also link to an open issue here)

CardView only-Date type should display only UTC dates with time 00:00:00

What is the new behaviour?
https://alfresco.atlassian.net/browse/HXCS-2818

Date Objects always switches to the local timezone, while maintaining the same instant as the UTC time.
That means 24th January 00:00:00 in Capo Verde is still 23th January, leading to incongruences in the UI, as it displays date in the local timezone.

The trick is to have different dates: those set in property (correct UTC value with T00:00:00Z) and those displayed in the UI. The latter can represent a different instant in time, but will have same day, month, year as the UTC value ignoring the local timezone.

Does this PR introduce a breaking change? (check one with "x")

  • Yes
  • No

If this PR contains a breaking change, please describe the impact and migration path for existing applications: ...

Other information:

@CLAassistant
Copy link

CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.


Adriano Costa seems not to be a GitHub user. You need a GitHub account to be able to sign the CLA. If you have already a GitHub account, please add the email address used for this commit to your account.
You have signed the CLA already but the status is still pending? Let us recheck it.

@wideLandscape wideLandscape changed the title Dev acosta hxcs 2818 force utc [HXCS-2818] CardViewDateItem component ignore timezone when displaying dates Feb 5, 2024
@wideLandscape wideLandscape force-pushed the dev-acosta-HXCS-2818-force-utc branch from ff95525 to 2a04c27 Compare February 5, 2024 15:27
Copy link

sonarqubecloud bot commented Feb 5, 2024

Quality Gate Passed Quality Gate passed

Kudos, no new issues were introduced!

0 New issues
0 Security Hotspots
No data about Coverage
0.0% Duplication on New Code

See analysis details on SonarCloud

@wideLandscape wideLandscape merged commit efd8e8d into develop Feb 5, 2024
32 of 33 checks passed
@wideLandscape wideLandscape deleted the dev-acosta-HXCS-2818-force-utc branch February 5, 2024 15:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants