lib/rademade_admin/model/reflection.rb in rademade_admin-0.1.3 vs lib/rademade_admin/model/reflection.rb in rademade_admin-0.1.4

- old
+ new

@@ -24,9 +24,13 @@ # @return [RademadeAdmin::Model::Adapter::Query] def query_adapter @query_adapter ||= "RademadeAdmin::Model::Adapter::Query::#{orm_type}".constantize.new(@model) end + def hideable? + _model_ancestors.include? RademadeAdmin::Hideable.name + end + protected def _model_ancestors @model_ancestors = @model.ancestors.map(&:to_s) end