Module: Effective::EffectiveDatatable::Collection

Included in:
Datatable
Defined in:
app/models/effective/effective_datatable/collection.rb

Instance Method Summary collapse

Instance Method Details

#active_record_collection?Boolean

Returns:

  • (Boolean)


10
11
12
# File 'app/models/effective/effective_datatable/collection.rb', line 10

def active_record_collection?
  @active_record_collection == true
end

#array_collection?Boolean

Returns:

  • (Boolean)


14
15
16
# File 'app/models/effective/effective_datatable/collection.rb', line 14

def array_collection?
  @array_collection == true
end

#collection_classObject

Used for authorization. We authorize with authorized?(:index, collection_class)



6
7
8
# File 'app/models/effective/effective_datatable/collection.rb', line 6

def collection_class
  @collection_class  # Will be either User/Post/etc or Array
end