diff options
Diffstat (limited to 'app/models/chouette/access_point.rb')
| -rw-r--r-- | app/models/chouette/access_point.rb | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/app/models/chouette/access_point.rb b/app/models/chouette/access_point.rb index da1f9524a..476f13c08 100644 --- a/app/models/chouette/access_point.rb +++ b/app/models/chouette/access_point.rb @@ -1,9 +1,10 @@ require 'geokit' require 'geo_ruby' -class Chouette::AccessPoint < Chouette::TridentActiveRecord +class Chouette::AccessPoint < Chouette::ActiveRecord # FIXME http://jira.codehaus.org/browse/JRUBY-6358 self.primary_key = "id" + include StifReflexAttributesSupport include Geokit::Mappable include ProjectionFields @@ -29,6 +30,10 @@ class Chouette::AccessPoint < Chouette::TridentActiveRecord before_save :coordinates_to_lat_lng + def referential + @referential ||= Referential.where(:slug => Apartment::Tenant.current).first! + end + def combine_lat_lng if self.latitude.nil? || self.longitude.nil? "" |
