From b2916c51c2945dd7e9cf66bd37278945c1ca233d Mon Sep 17 00:00:00 2001 From: aozhiwei Date: Fri, 20 Nov 2020 16:14:42 +0800 Subject: [PATCH] 1 --- .../controller/ActivityController.class.php | 46 ++++++++++--------- 1 file changed, 25 insertions(+), 21 deletions(-) diff --git a/webapp/controller/ActivityController.class.php b/webapp/controller/ActivityController.class.php index 4703236..d711841 100644 --- a/webapp/controller/ActivityController.class.php +++ b/webapp/controller/ActivityController.class.php @@ -338,7 +338,8 @@ class ActivityController{ $day = 1; if (phpcommon\extractChannel($account_id) == 6001 || phpcommon\extractChannel($account_id) == 6000 || - phpcommon\extractChannel($account_id) == 6006) { + phpcommon\extractChannel($account_id) == 6006 || + phpcommon\extractChannel($account_id) == 6007) { $day = $row['now_days']; } $g_conf_lot_cluster = require('../res/lottery@lottery.php'); @@ -350,23 +351,23 @@ class ActivityController{ )); } } - for ($i1 = 0; $i1 < count($lot_array); $i1++) { - $l = $this->getLottery($lot_array[$i1]['key']); - $weight_sum += $l['jilv']; - } - $random = Rand(0, 100); - if ($random >= 50) { - $key = $lot_array[0]['key']; - } else { - $key = $lot_array[1]['key']; - } - } else if ($row['free_times'] + $row['video_times'] + 1 == 6) { - foreach ($user_db['draw_list'] as $draw) { - if (isset($draw['status']) && $draw['status'] != 0) { - continue; - } - $key = $draw['key'] + 1; - } + // for ($i1 = 0; $i1 < count($lot_array); $i1++) { + // $l = $this->getLottery($lot_array[$i1]['key']); + // $weight_sum += $l['jilv']; + // } + //$random = Rand(0, 100); + //if ($random >= 50) { + $key = $lot_array[0]['key']; + // } else { + // $key = $lot_array[1]['key']; + // } + // } else if ($row['free_times'] + $row['video_times'] + 1 == 6) { + // foreach ($user_db['draw_list'] as $draw) { + // if (isset($draw['status']) && $draw['status'] != 0) { + // continue; + // } + // $key = $draw['key'] + 1; + // } } else { foreach ($user_db['draw_list'] as $draw) { if (isset($draw['status']) && $draw['status'] != 0) { @@ -808,7 +809,8 @@ class ActivityController{ $day = 1; if (phpcommon\extractChannel($account_id) == DOUYIN_CHANNEL || phpcommon\extractChannel($account_id) == 6001 || - phpcommon\extractChannel($account_id) == 6000) { + phpcommon\extractChannel($account_id) == 6000 || + phpcommon\extractChannel($account_id) == 6007) { $day = date('w', time()); if ($day == 0) { $day = 7; @@ -1010,7 +1012,8 @@ class ActivityController{ $day = 1; if ($type == 1) { if (phpcommon\extractChannel($accountid) == 6001 || - phpcommon\extractChannel($accountid) == 6000) { + phpcommon\extractChannel($accountid) == 6000 || + phpcommon\extractChannel($accountid) == 6007) { $day = $days; } } @@ -1077,7 +1080,8 @@ class ActivityController{ if ($type == 1) { if (phpcommon\extractChannel($accountid) == 6001 || phpcommon\extractChannel($accountid) == 6006 || - phpcommon\extractChannel($accountid) == 6000) { + phpcommon\extractChannel($accountid) == 6000 || + phpcommon\extractChannel($accountid) == 6007) { $day = date('w', time()); if ($day == 0) { $day = 7;