Introduce the pagination feature to TriggersView and LatestView

This modification introduces the pagination feature to TriggersView and LatestView.
To calculate the number of pages, it also adds functions to get total number of items.
(The function to getting total number of triggers is already exists.)