Gmaps4rails与kaminari不兼容

时间:2014-06-01 02:49:55

标签: ruby-on-rails postgresql ruby-on-rails-4 kaminari

我有一个模型,地理定位工作正常,分页(通过限制/偏移)像kaminari和will_paginate,工作正常。分别。然而,他们一起向我提出了这个错误。

Location.near(postcode, 5) # works fine

Location.all.page(1) # works fine

Location.near(postcode, 5).page(1) #gives me the following error...

PG::UndefinedColumn: ERROR:  column "distance" does not exist

有什么想法吗?提前致谢

0 个答案:

没有答案