summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFelix Dörre <felix@dogcraft.de>2015-04-19 15:07:06 +0200
committerFelix Dörre <felix@dogcraft.de>2015-04-21 21:15:03 +0200
commit532c4e7d06f7e30d7f1a4e99020d315aa948764a (patch)
treea6ae245ed7668a5e3b9a66b9c0e36cdf12fee9be
parent7ad2ae283710f934e73e26baf8e279cc0f462620 (diff)
downloadcacert-devel-532c4e7d06f7e30d7f1a4e99020d315aa948764a.tar.gz
cacert-devel-532c4e7d06f7e30d7f1a4e99020d315aa948764a.tar.xz
cacert-devel-532c4e7d06f7e30d7f1a4e99020d315aa948764a.zip
UPD: fixup for 'administrativ-increase-assurances' in refresh_stats.phpbug-1051
-rwxr-xr-xscripts/cron/refresh_stats.php8
1 files changed, 4 insertions, 4 deletions
diff --git a/scripts/cron/refresh_stats.php b/scripts/cron/refresh_stats.php
index 6619b29..2d6b2de 100755
--- a/scripts/cron/refresh_stats.php
+++ b/scripts/cron/refresh_stats.php
@@ -122,7 +122,7 @@ function getDataFromLive() {
$stats['users_1to49'] = number_format(tc(
"select count(*) as `count` from (
select 1 from `notary`
- where `deleted` = 0
+ where `deleted` = 0 AND `method` != 'Administrative Increase' AND `from` != `to`
group by `to`
having sum(`awarded`) > 0 and sum(`awarded`) < 50
) as `low_points`"));
@@ -130,7 +130,7 @@ function getDataFromLive() {
$stats['users_50to99'] = number_format(tc(
"select count(*) as `count` from (
select 1 from `notary`
- where `deleted` = 0
+ where `deleted` = 0 AND `method` != 'Administrative Increase' AND `from` != `to`
group by `to`
having sum(`awarded`) >= 50 and sum(`awarded`) < 100
) as `high_points`"));
@@ -139,7 +139,7 @@ function getDataFromLive() {
"select count(*) as `count` from `users`
where (
select sum(`awarded`) from `notary`
- where `to`=`users`.`id`
+ where `to`=`users`.`id` AND `method` != 'Administrative Increase' AND `from` != `to`
and `deleted` = 0
) >= 100
and not exists(
@@ -154,7 +154,7 @@ function getDataFromLive() {
"select count(*) as `count` from `users`
where (
select sum(`awarded`) from `notary`
- where `to`=`users`.`id`
+ where `to`=`users`.`id` AND `method` != 'Administrative Increase' AND `from` != `to`
and `deleted` = 0
) >= 100
and exists(