File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 2525class PagerRenderer
2626{
2727 /**
28- * First page number.
28+ * First page number in the current pages being displayed .
2929 *
3030 * @var int
3131 */
3232 protected $ first ;
3333
3434 /**
35- * Last page number.
35+ * Last page number in the current pages being displayed .
3636 *
3737 * @var int
3838 */
@@ -85,8 +85,11 @@ class PagerRenderer
8585 */
8686 public function __construct (array $ details )
8787 {
88- $ this ->first = 1 ;
89- $ this ->last = $ details ['pageCount ' ];
88+ // `first` and `last` will be updated by `setSurroundCount()`.
89+ // You must call `setSurroundCount()` after instantiation.
90+ $ this ->first = 1 ;
91+ $ this ->last = $ details ['pageCount ' ];
92+
9093 $ this ->current = $ details ['currentPage ' ];
9194 $ this ->total = $ details ['total ' ];
9295 $ this ->uri = $ details ['uri ' ];
@@ -377,7 +380,7 @@ public function getNextPage()
377380 }
378381
379382 /**
380- * Returns the page number of the first page.
383+ * Returns the page number of the first page in the current pages being displayed .
381384 */
382385 public function getFirstPageNumber (): int
383386 {
@@ -393,7 +396,7 @@ public function getCurrentPageNumber(): int
393396 }
394397
395398 /**
396- * Returns the page number of the last page.
399+ * Returns the page number of the last page in the current pages being displayed .
397400 */
398401 public function getLastPageNumber (): int
399402 {
You can’t perform that action at this time.
0 commit comments