ruby on rails - how to set time zone for mongoid -


I am using mongoid for my rail app.

I want to set the timezone for Mangode.

I tried it in application.rb with

  config.mongoid.time_zone = 'Kolkata'   

but no luck . I also tried it with

  use_utc: false use_activesupport_time_zone: true   

However this default time zone uses UTC.

Rail 3.0 10

mongoid 2.2.4

Please help.

Thanks in advance.

In this way, in application.rb

  config.time_zone =   

and yam in coral

  use_activesupport_time_zone: true    

Comments