Guest User

Untitled

a guest
Jul 22nd, 2018
85
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.26 KB | None | 0 0
  1. # If you're building the JSON provider with Rails,
  2. # add to the as_json method of TimeWtihZone by adding
  3. # this file to your config/initializers/
  4.  
  5. class ActiveSupport::TimeWithZone
  6. def as_json(options = {})
  7. strftime('%Y/%m/%d %H:%M:%S %z')
  8. end
  9. end
Add Comment
Please, Sign In to add comment