Class: Goldencobra::Location
- Inherits:
-
ActiveRecord::Base
- Object
- ActiveRecord::Base
- Goldencobra::Location
- Defined in:
- app/models/goldencobra/location.rb
Instance Attribute Summary collapse
-
#skip_geocode ⇒ Object
Returns the value of attribute skip_geocode.
Instance Method Summary collapse
Instance Attribute Details
#skip_geocode ⇒ Object
Returns the value of attribute skip_geocode.
25 26 27 |
# File 'app/models/goldencobra/location.rb', line 25 def skip_geocode @skip_geocode end |
Instance Method Details
#complete_location ⇒ Object
29 30 31 32 33 34 35 |
# File 'app/models/goldencobra/location.rb', line 29 def complete_location result = "" result += "#{self.street}" if self.street.present? result += " #{self.street_number}" if self.street_number.present? result += ", #{self.zip}" if self.zip.present? result += " #{self.city}" if self.city.present? end |
#skip_geocoding_once_or_always ⇒ Object
41 42 43 |
# File 'app/models/goldencobra/location.rb', line 41 def skip_geocoding_once_or_always self.skip_geocode || self.manual_geocoding end |
#title ⇒ Object
37 38 39 |
# File 'app/models/goldencobra/location.rb', line 37 def title self.complete_location end |