module GeoQuery::GeoQueryable::ClassMethods
Public Instance Methods
geo_queryable(options = {})
click to toggle source
Init method
# File lib/geo_query/geo_queryable.rb, line 66 def geo_queryable(options = {}) self.base_class.point_column = options[:column] || :coordinates self.base_class.track_updates = options[:track_updates] || false # Validations validate :save_coordinates if self.base_class.track_updates # Callbacks before_save :set_location_updated_at, if: :location_did_change? end end