Skip to content

Instantly share code, notes, and snippets.

@zxiest
Created March 22, 2011 21:07
Show Gist options
  • Save zxiest/882061 to your computer and use it in GitHub Desktop.
Save zxiest/882061 to your computer and use it in GitHub Desktop.
module LocationsHelper
def self.detailed_information(location)
detailed_information =[ ["Accepts credit cards?", location.accepts_credit_cards] ]
unless location.smoking_policy.nil?
detailed_information << [ "Smoking Policy", location.smoking_policy]
end
unless location.center.nil?
detailed_information << ["Center" , location.center.name, center_path(location.center.id)]
end
detailed_information
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment