Module: AzaharaSchema::CanCan::ControllerResourcePatch
- Defined in:
- lib/azahara_schema/cancan/controller_resource_patch.rb
Instance Method Summary collapse
Instance Method Details
#load_collection ⇒ Object
6 7 8 9 10 11 12 13 |
# File 'lib/azahara_schema/cancan/controller_resource_patch.rb', line 6 def load_collection schema = ::AzaharaSchema::Schema.schema_for(resource_class) if @options[:trough] schema.add_filter(parent_name.to_s+'_id', '=', parent_resource.id) end schema.visibility_scope!(current_ability, ) schema end |