cethyworks/doctrine-paginator-decorator

Doctrine Paginator 的装饰器/辅助工具

安装: 272

依赖项: 0

建议者: 0

安全性: 0

星标: 0

关注者: 2

分支: 0

公开问题: 0

类型:symfony-bundle

v1.0 2017-07-10 12:49 UTC

This package is not auto-updated.

Last update: 2024-09-20 20:11:02 UTC


README

Doctrine\ORM\Tools\Pagination\Paginator 的装饰器/辅助工具。

CircleCI

安装

1. 使用 Composer 安装

$ composer require cethyworks/doctrine-paginator-decorator

如何使用

$paginator = new DoctrinePaginatorDecorator($queryBuilder, $currentPage, $limitPerPage);

$paginator->getPage(); // return current page
$paginator->getLimit(); // return limit per page
$paginator->hasNextPage(); // return true if there is enough result for a next page
$paginator->getCount(); // return total entity count
$paginator->getList(); // return entity list for current page