Class: Thredded::Stats
- Inherits:
-
Object
- Object
- Thredded::Stats
- Includes:
- ActionView::Helpers::NumberHelper
- Defined in:
- app/models/thredded/stats.rb
Instance Method Summary collapse
Instance Method Details
#messageboards_count ⇒ Object
6 7 8 |
# File 'app/models/thredded/stats.rb', line 6 def number_to_human(.count, precision: 4) end |
#posts_count ⇒ Object
14 15 16 |
# File 'app/models/thredded/stats.rb', line 14 def posts_count number_to_human(.map(&:posts_count).sum, precision: 5) end |
#topics_count ⇒ Object
10 11 12 |
# File 'app/models/thredded/stats.rb', line 10 def topics_count number_to_human(.map(&:topics_count).sum, precision: 4) end |