Created a view model for pagination