secondbase icon indicating copy to clipboard operation
secondbase copied to clipboard

Secondbase no longer works with Ransack gem.

Open lcpriest opened this issue 7 years ago • 1 comments

I noticed this when using Secondbase with ActiveAdmin. The change occurred 10 days in this commit.

https://github.com/activerecord-hackery/ransack/commit/d44575506ccc7cb00e618256707ed53732a07bca

As you can see, moving from schema_cache = @engine.connection.schema_cache to schema_cache = ::ActiveRecord::Base.connection.schema_cache will exclude SecondBase tables.

It will now throw an error "RuntimeError (No table named #{table_name} exists.)" when attempting to use custom filters like "#{column_name}_contains"

lcpriest avatar Feb 13 '18 03:02 lcpriest

Good to know. In general, I've seen updates like this to Arel ruin my day when doing SQL Server adapter work. Often times that remove private ivars that were critical for 3rd party gems that rails-core never used or saw a need for.

I have subscribed to the Ransack issue to follow along and see where this goes. Thanks!

metaskills avatar Feb 13 '18 16:02 metaskills