From 312448c72471ed5f4b426d238327e9c1dfb3ccca Mon Sep 17 00:00:00 2001 From: yulingwei <2436953959@qq.com> Date: Mon, 13 Apr 2020 09:57:01 +0800 Subject: [PATCH] upt --- Application/Admin/Controller/StatisticsController.class.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Application/Admin/Controller/StatisticsController.class.php b/Application/Admin/Controller/StatisticsController.class.php index bca403702..bc2fd58b6 100644 --- a/Application/Admin/Controller/StatisticsController.class.php +++ b/Application/Admin/Controller/StatisticsController.class.php @@ -1172,7 +1172,7 @@ class StatisticsController extends ThinkController { $pdlMap .= " and pdl.create_time < {$endTime}"; } - if ($info['level'] == PromoteModel::LEVEL_GROUP_LEADER) { + if ($level == PromoteModel::LEVEL_TEAM_MEMBER) { $beginThisweek = mktime(0, 0 , 0,date("m"),date("d")-date("w")+1,date("Y")); $endThisweek = mktime(23,59,59,date("m"),date("d")-date("w")+7,date("Y")); $list = M('promote', 'tab_')->alias('p') @@ -1183,6 +1183,7 @@ class StatisticsController extends ThinkController { ->page($p, $row) ->group('p.id') ->select(); + $total = M('promote', 'tab_')->alias('p') ->field('count(distinct(u.id)) as iosCount, count(distinct(if (u.register_time between '. $beginThisweek . ' and ' . $endThisweek .', 1, null))) as weekCount, count(if(pdl.type = 1, 1, null)) as signCount, count(if(pdl.type = 2, 1, null)) as tfCount, count(if(pdl.type = 3, 1, null)) as superSignCount') ->join("tab_package_download_log pdl on pdl.promote_id = p.id $pdlMap", 'left')