Skip to content

Instantly share code, notes, and snippets.

@softwaregravy
Created March 13, 2011 20:30
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save softwaregravy/868411 to your computer and use it in GitHub Desktop.
Save softwaregravy/868411 to your computer and use it in GitHub Desktop.
def serializable_hash(options = {})
# TODO exclude the id
options = {:include => [:address, :location, :hours_of_operations, :slow_periods, :discounts],
:except => [:created_at, :updated_at, :creating_user_id]}.merge(options ||= {})
super options
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment