mirror of
https://github.com/openvk/openvk
synced 2025-04-23 08:33:02 +03:00
Reswitch getting counts
This commit is contained in:
parent
2ee9f5d22c
commit
02b6022cc3
3 changed files with 4 additions and 4 deletions
|
@ -74,7 +74,7 @@ final class WallPresenter extends OpenVKPresenter
|
||||||
$this->template->paginatorConf = (object) [
|
$this->template->paginatorConf = (object) [
|
||||||
"count" => $this->template->count,
|
"count" => $this->template->count,
|
||||||
"page" => (int) ($_GET["p"] ?? 1),
|
"page" => (int) ($_GET["p"] ?? 1),
|
||||||
"amount" => sizeof((array)$this->template->posts),
|
"amount" => $this->template->posts->count(),
|
||||||
"perPage" => OPENVK_DEFAULT_PER_PAGE,
|
"perPage" => OPENVK_DEFAULT_PER_PAGE,
|
||||||
];
|
];
|
||||||
|
|
||||||
|
@ -332,7 +332,7 @@ final class WallPresenter extends OpenVKPresenter
|
||||||
foreach($photos as $photo)
|
foreach($photos as $photo)
|
||||||
$post->attach($photo);
|
$post->attach($photo);
|
||||||
|
|
||||||
if(sizeof($videos) > 0)
|
if($videos->count() > 0)
|
||||||
foreach($videos as $vid)
|
foreach($videos as $vid)
|
||||||
$post->attach($vid);
|
$post->attach($vid);
|
||||||
|
|
||||||
|
|
|
@ -9,7 +9,7 @@
|
||||||
{/block}
|
{/block}
|
||||||
|
|
||||||
{block content}
|
{block content}
|
||||||
{var $amount = sizeof((array)$logs)}
|
{var $amount = $logs->count()}
|
||||||
|
|
||||||
<style>
|
<style>
|
||||||
del, ins { text-decoration: none; color: #000; }
|
del, ins { text-decoration: none; color: #000; }
|
||||||
|
|
|
@ -142,7 +142,7 @@
|
||||||
{include "../components/paginator.xml", conf => (object) [
|
{include "../components/paginator.xml", conf => (object) [
|
||||||
"page" => $page,
|
"page" => $page,
|
||||||
"count" => $count,
|
"count" => $count,
|
||||||
"amount" => sizeof((array)$data),
|
"amount" => $data->count(),
|
||||||
"perPage" => $perPage ?? OPENVK_DEFAULT_PER_PAGE,
|
"perPage" => $perPage ?? OPENVK_DEFAULT_PER_PAGE,
|
||||||
"atBottom" => false,
|
"atBottom" => false,
|
||||||
]}
|
]}
|
||||||
|
|
Loading…
Reference in a new issue