From 8fbc62a801640ac6e75e103223f946f8aed83bee Mon Sep 17 00:00:00 2001 From: aozhiwei Date: Fri, 11 Sep 2020 18:58:22 +0800 Subject: [PATCH] 1 --- webapp/controller/SignController.class.php | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/webapp/controller/SignController.class.php b/webapp/controller/SignController.class.php index 564e978..24f9439 100644 --- a/webapp/controller/SignController.class.php +++ b/webapp/controller/SignController.class.php @@ -250,7 +250,7 @@ class SignController{ $dayid = ($week - 1) * 7; //如果大于配置表最后一周,按最后一周奖励 $g_conf_sign_cluster = require('../res/signDaily@signDaily.php'); - if ($dayid + 1 > count($g_conf_sign_cluster)) { + if ($dayid + 1 >= count($g_conf_sign_cluster)) { $dayid = count($g_conf_sign_cluster) - 7; } //error_log($dayid); @@ -321,8 +321,8 @@ class SignController{ $dayid = ($week - 1) * 7 + $_REQUEST['sign_id']; //如果大于配置表最后一周,按最后一周奖励 $g_conf_sign_cluster = require('../res/signDaily@signDaily.php'); - if ($dayid > count($g_conf_sign_cluster)) { - $dayid = count($g_conf_sign_cluster) - 7; + if ($dayid >= count($g_conf_sign_cluster)) { + $dayid = count($g_conf_sign_cluster) + $_REQUEST['sign_id'] - 7; } //$dayid = $_REQUEST['sign_id']; $s = $this->getSign($dayid + 90000); @@ -411,8 +411,8 @@ class SignController{ $dayid = ($week - 1) * 7 + $_REQUEST['sign_id']; //如果大于配置表最后一周,按最后一周奖励 $g_conf_sign_cluster = require('../res/signDaily@signDaily.php'); - if ($dayid > count($g_conf_sign_cluster)) { - $dayid = count($g_conf_sign_cluster) - 7; + if ($dayid >= count($g_conf_sign_cluster)) { + $dayid = count($g_conf_sign_cluster) + $_REQUEST['sign_id'] - 7; } //$dayid = $_REQUEST['sign_id'];