Refactoring of the pager
Added default sort index
Removed as not used.