1
0
Fork 0
mirror of https://github.com/kaminari/kaminari.git synced 2022-11-09 13:44:37 -05:00
This commit is contained in:
Akira Matsuda 2016-12-08 16:25:08 +09:00
parent 106273c202
commit bd8fabafe7

View file

@ -106,9 +106,7 @@ module Kaminari
if collection.total_pages < 2 if collection.total_pages < 2
t('helpers.page_entries_info.one_page.display_entries', entry_name: entry_name, count: collection.total_count) t('helpers.page_entries_info.one_page.display_entries', entry_name: entry_name, count: collection.total_count)
else else
first = collection.offset_value + 1 t('helpers.page_entries_info.more_pages.display_entries', entry_name: entry_name, first: collection.offset_value + 1, last: [collection.offset_value + collection.limit_value, collection.total_count].min, total: collection.total_count)
last = (sum = collection.offset_value + collection.limit_value) > collection.total_count ? collection.total_count : sum
t('helpers.page_entries_info.more_pages.display_entries', entry_name: entry_name, first: first, last: last, total: collection.total_count)
end.html_safe end.html_safe
end end