FIX
This commit is contained in:
parent
8a8408302e
commit
5bdeeaa5c0
|
|
@ -38,9 +38,12 @@ class PageController extends Controller
|
||||||
}
|
}
|
||||||
// ------------------------------------------
|
// ------------------------------------------
|
||||||
|
|
||||||
|
$param = array();
|
||||||
|
$param['where'] = '`moderate` = 1';
|
||||||
$pointsCount = Point::model()->getCount($param);
|
$pointsCount = Point::model()->getCount($param);
|
||||||
$pagesCount = ceil($pointsCount/self::elementsByPage);
|
$pagesCount = ceil($pointsCount/self::elementsByPage);
|
||||||
$page = isset($_GET['page']) ? abs((int)$_GET['page']) : $pagesCount;
|
$page = isset($_GET['page']) ? abs((int)$_GET['page']) : $pagesCount;
|
||||||
|
|
||||||
$param = array();
|
$param = array();
|
||||||
$param['order'] = 'id DESC';
|
$param['order'] = 'id DESC';
|
||||||
if (App::getParam('category')) {
|
if (App::getParam('category')) {
|
||||||
|
|
|
||||||
|
|
@ -59,7 +59,7 @@ if (App::getParam('user')) {
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<?php if (!(int) App::getParam('category')):?>
|
<?php if (!(int) App::getParam('category') && !(int) App::getParam('user')):?>
|
||||||
<nav>
|
<nav>
|
||||||
<ul class="pagination">
|
<ul class="pagination">
|
||||||
<li class="<?= ($page >= $pagesCount) ? 'disabled' : '' ?>">
|
<li class="<?= ($page >= $pagesCount) ? 'disabled' : '' ?>">
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue