<?php
function getPaginationData($page, $perPage, $total) {
    return [
        'current_page' => (int)$page,
        'per_page' => (int)$perPage,
        'total' => (int)$total,
        'last_page' => (int)ceil($total / $perPage)
    ];
}
