Module: Effective::EffectiveDatatable::Cookie
- Included in:
- Datatable
- Defined in:
- app/models/effective/effective_datatable/cookie.rb
Constant Summary collapse
- MAX_COOKIE_SIZE =
String size. Real byte size is about 1.5 times bigger.
2500
Instance Method Summary collapse
- #cookie ⇒ Object
- #cookie_key ⇒ Object
-
#cookie_keys ⇒ Object
All possible dt cookie keys.
- #cookie_param ⇒ Object
Instance Method Details
#cookie ⇒ Object
6 7 8 |
# File 'app/models/effective/effective_datatable/cookie.rb', line 6 def end |
#cookie_key ⇒ Object
10 11 12 |
# File 'app/models/effective/effective_datatable/cookie.rb', line 10 def ||= (datatables_ajax_request? ? view.params[:cookie] : ) end |
#cookie_keys ⇒ Object
All possible dt cookie keys. Used to make sure the datatable has a cookie set for this session.
15 16 17 |
# File 'app/models/effective/effective_datatable/cookie.rb', line 15 def ||= Array().compact.map(&:first) end |
#cookie_param ⇒ Object
19 20 21 |
# File 'app/models/effective/effective_datatable/cookie.rb', line 19 def [self.class, attributes].hash.to_s.last(12) end |