From 2702b69a03de5685cdf3fc6cdde9b1b4d0d40ccb Mon Sep 17 00:00:00 2001 From: Krivchikov Dmitry Date: Mon, 16 Nov 2015 00:07:38 +0300 Subject: [PATCH] =?UTF-8?q?FIX=20=D0=BF=D0=BE=D0=B4=D1=81=D1=87=D1=91?= =?UTF-8?q?=D1=82=20=D0=BA=D0=BE=D0=BB-=D0=B2=D0=B0=20=D1=81=D0=BE=D0=B7?= =?UTF-8?q?=D0=B4=D0=B0=D0=BD=D0=BD=D1=8B=D1=85=20=D1=82=D0=BE=D1=87=D0=B5?= =?UTF-8?q?=D0=BA=20-=20=D1=82=D0=B5=D0=BF=D0=B5=D1=80=D1=8C=20=D1=82?= =?UTF-8?q?=D0=BE=D0=BB=D1=8C=D0=BA=D0=BE=20=D0=BE=D0=BF=D1=83=D0=B1=D0=BB?= =?UTF-8?q?=D0=B8=D0=BA=D0=BE=D0=B2=D0=B0=D0=BD=D0=BD=D1=8B=D0=B5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- ground/models/Point.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ground/models/Point.php b/ground/models/Point.php index 792a0e2..cff7f8e 100644 --- a/ground/models/Point.php +++ b/ground/models/Point.php @@ -81,7 +81,7 @@ class Point extends Model public function getCountByUser($userId) { - $res = App::DB()->query('SELECT count(`id`) AS `cnt` FROM ' . $this->_tableName_ . ' WHERE `author` = ' . $userId . ' ;')->fetch(PDO::FETCH_ASSOC); + $res = App::DB()->query('SELECT count(`id`) AS `cnt` FROM ' . $this->_tableName_ . ' WHERE `author` = ' . $userId . ' AND `moderate` = 1 ;')->fetch(PDO::FETCH_ASSOC); return $res['cnt']; }