Module: BootstrapPager::MongoidCriteriaMethods

Defined in:
lib/bootstrap_pager/models/mongoid_criteria_methods.rb

Instance Method Summary collapse

Instance Method Details

#limit_valueObject

:nodoc:


3
4
5
# File 'lib/bootstrap_pager/models/mongoid_criteria_methods.rb', line 3

def limit_value #:nodoc:
  options[:limit]
end

#offset_valueObject

:nodoc:


7
8
9
# File 'lib/bootstrap_pager/models/mongoid_criteria_methods.rb', line 7

def offset_value #:nodoc:
  options[:skip]
end

#total_countObject

:nodoc:


11
12
13
# File 'lib/bootstrap_pager/models/mongoid_criteria_methods.rb', line 11

def total_count #:nodoc:
  embedded? ? unpage.count : count
end