mirror of
https://github.com/openvk/openvk
synced 2024-11-11 01:19:53 +03:00
Admin: Fixed the critical error that was been caused by outdated function findCount()
This commit is contained in:
parent
7f1a5f2354
commit
10d2d6ed44
2 changed files with 3 additions and 3 deletions
|
@ -21,8 +21,8 @@ final class AdminPresenter extends OpenVKPresenter
|
|||
$query = $this->queryParam("q") ?? "";
|
||||
$page = (int) ($this->queryParam("p") ?? 1);
|
||||
|
||||
$count = $repo->findCount($query);
|
||||
return $repo->find($query, $page);
|
||||
$count = $repo->find($query)->size();
|
||||
return $repo->find($query)->page($page, 20);
|
||||
}
|
||||
|
||||
function onStartup(): void
|
||||
|
|
|
@ -58,7 +58,7 @@
|
|||
</table>
|
||||
<br/>
|
||||
<div align="right">
|
||||
{var isLast = ((10 * (($_GET['p'] ?? 1) - 1)) + $amount) < $count}
|
||||
{var isLast = ((20 * (($_GET['p'] ?? 1) - 1)) + $amount) < $count}
|
||||
|
||||
<a n:if="($_GET['p'] ?? 1) > 1" class="aui-button" href="?p={($_GET['p'] ?? 1) - 1}">
|
||||
⭁ туда
|
||||
|
|
Loading…
Reference in a new issue