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

Specify timezone #3

Open
dkrusenstrahle opened this issue Oct 20, 2013 · 2 comments
Open

Specify timezone #3

dkrusenstrahle opened this issue Oct 20, 2013 · 2 comments

Comments

@dkrusenstrahle
Copy link

Hello,

How can I set timezone?
When I select a date it automatically saves it in UTC format which is wrong here in Sweden.

Thanks!

@shekibobo
Copy link
Owner

TimeSplitter uses a default time of zero. You can override this by passing your own Time value in a lambda for the default option of split_accessor. Something like default: ->{Time.zone.now}

@idrinkpabst
Copy link

Hello. Great gem!
You might want to add something about the timezone to the README, because when I first used the gem, it was saving my dates as one day off because my Rails config.time_zone = 'Eastern Time (US & Canada)'. So starting with a default time in UTC and then changing it was causing havoc. Setting default: ->{Time.zone.now} fixed the issue.

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

No branches or pull requests

3 participants