\Framework\UtilsPagination

Summary

Methods
Properties
Constants
__construct()
getCurrentPage()
getTotalPages()
getTotal()
getPageSize()
getOffset()
getLimit()
getData()
No public properties found
No constants found
No protected methods found
No protected properties found
N/A
buildUrl()
$total
$size
$currentPage
$totalPages
$baseUrl
$baseQueryParams
N/A

Properties

$total

$total : int

Type

int

$size

$size : int

Type

int

$currentPage

$currentPage : int

Type

int

$totalPages

$totalPages : int

Type

int

$baseUrl

$baseUrl : string

Type

string

$baseQueryParams

$baseQueryParams : array

Type

array

Methods

__construct()

__construct(int  $total, \Symfony\Component\HttpFoundation\Request  $request, int  $size = 10) : mixed

Parameters

int $total
\Symfony\Component\HttpFoundation\Request $request
int $size

Returns

mixed —

getCurrentPage()

getCurrentPage() : int

Returns

int —

getTotalPages()

getTotalPages() : int

Returns

int —

getTotal()

getTotal() : int

Returns

int —

getPageSize()

getPageSize() : int

Returns

int —

getOffset()

getOffset() : int

Returns

int —

getLimit()

getLimit() : int

Returns

int —

getData()

getData(int  $radius = 2) : array

生成分页数据结构.

Parameters

int $radius

中间显示的页码半径(默认2,即左右各2页)

Returns

array —

buildUrl()

buildUrl(int  $page) : string

Parameters

int $page

Returns

string —