在rails 3.2.11上,地理编码器版本1.1.8
在我的模型中:
class Venue
include Mongoid::Document
include Geocoder::Model::Mongoid
....
field :address, type: String
field :latitude, type: Float
field :longitude, type: Float
....
geocoded_by :address
after_validation :geocode, :if => :address_changed?
.....
end当我尝试创建一个新的会场时,我得到了一个错误,该错误被追踪到Venue.create的控制器
undefined method `coordinates=' for #<Venue....为了切入正题,我在安装gem之后运行了bundle install并重启了应用服务器。
提前谢谢。
发布于 2013-07-17 09:21:31
https://stackoverflow.com/questions/17689387
复制相似问题