Skip to content

Instantly share code, notes, and snippets.

@voxxit
Created September 25, 2009 02:27
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 voxxit/193233 to your computer and use it in GitHub Desktop.
Save voxxit/193233 to your computer and use it in GitHub Desktop.
hostroute = Brand.find_by_name("Hostroute")
ultraspeed = Brand.find_by_name("Ultraspeed")
core_brand = case class_id
when 1 then ultraspeed
when 2 then hostroute
when 5 then hostroute
else
hostroute
end
core_country = Country.find_by_name(country)
core_state = case active
when 0 then "deleted"
when 1 then "active"
else
"pending"
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment