Module: ForestLiana::SchemaHelper

Defined in:
app/helpers/forest_liana/schema_helper.rb

Class Method Summary collapse

Class Method Details

.find_collection_from_model(active_record_class) ⇒ Object



3
4
5
6
# File 'app/helpers/forest_liana/schema_helper.rb', line 3

def self.find_collection_from_model(active_record_class)
  collection_name = ForestLiana.name_for(active_record_class)
  ForestLiana.apimap.find { |collection| collection.name.to_s == collection_name }
end