DatePicker timezone problem

See original GitHub issue

[bsConfig]="{ dateInputFormat: 'YYYY-MM-DD' }"

when this format is used, i may expect the same entry come back regardless of client. because we are selecting a date not datetime. But its considering it as datetime and puts timezone info to it.

So, for example, 2018-01-30 00:00:00 becomes 2018-01-29 if your timezone is +

There is no config option to set timezone or any thing that allows to retreive the input directly.

If there is a way, i am not aware but per the source code, i dont see any option that lets this.

Issue Analytics

  • State:open
  • Created 6 years ago
  • Reactions:67
  • Comments:47 (8 by maintainers)

github_iconTop GitHub Comments

18reactions
isaloxcommented, Nov 21, 2019

@isalox you could try my workaround solution that i post before. a utc date wrapper for ngx-bootstrap for version before 5.2.0 @Domainv No. Still have some problem in https://stackblitz.com/edit/angular-mb7szh. It work fine when setDate button is pressed. But when the date is selected by datepicker, it do not work.

image

image

image

I don’t need any workarounds. It should work properly without any hacks. It is basic functionality for datepicker. If it can’t render date correctly why do anyone need it. Right now it is useless. Hope it will be fixed in next release.

17reactions
Omi231commented, Feb 11, 2020

Any idea when a fix will be available?

I came to check this issue after 1 year and mods still need info about the issue. Maybe in year 3020 they will find root cause and in year 4020 it is expected to be solved.

Read more comments on GitHub >

github_iconTop Results From Across the Web

[DatePicker] Incorrect TimeZones · Issue #882 - GitHub
Description: There seems to be some strange behavior with time zones with the new date picker I am in New Zealand so our...
Read more >
Date Picker get Date in given timezone instead of local time
1 Answer 1 · Have the Date Picker UI always provide a date in UTC (typically at midnight UTC), then add your user's...
Read more >
Handling the time zone issue in Material Date Picker ... - Reddit
There seems to be a issue related to time zone in Material Date Picker which shows wrong dates for default selection, current date,...
Read more >
dateBox and datePicker can return wrong date [36756029]
The date the user selects is in their own timezone, and when you convert it to a string server side it uses the...
Read more >
Date Picker Sends Wrong Date - Power Platform Community
Excel's default time zone is UTC. · PowerApps' default time zone is local time zone. · So when PowerApps load time, it will...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found