From 463382a641b82ff1869478988a9f67a193c9fdf6 Mon Sep 17 00:00:00 2001 From: evoxwht <442384644@qq.com> Date: Thu, 1 Jun 2023 09:28:50 +0800 Subject: [PATCH] =?UTF-8?q?=E5=A4=84=E7=90=86=E7=AD=BE=E5=88=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- crmeb/app/services/user/UserSignServices.php | 20 ++++++++----------- .../uni-app/pages/users/user_sgin/index.vue | 2 +- 2 files changed, 9 insertions(+), 13 deletions(-) diff --git a/crmeb/app/services/user/UserSignServices.php b/crmeb/app/services/user/UserSignServices.php index b3d8c8de4..d3e1d9651 100644 --- a/crmeb/app/services/user/UserSignServices.php +++ b/crmeb/app/services/user/UserSignServices.php @@ -139,21 +139,17 @@ class UserSignServices extends BaseServices if (!$user) { throw new ApiException(410032); } - if ($this->getIsSign($uid, 'today')) { - throw new ApiException(410293); - } +// if ($this->getIsSign($uid, 'today')) { +// throw new ApiException(410293); +// } $sign_num = 0; - $user_sign_num = $user['sign_num']; //检测昨天是否签到 - if ($this->getIsSign($uid, 'yesterday')) { - if ($user->sign_num > (count($sign_list) - 1)) { - $user->sign_num = 0; - } - } else { - $user->sign_num = 0; - } +// if (!$this->getIsSign($uid, 'yesterday')) { +// $user->sign_num = 0; +// } + foreach ($sign_list as $key => $item) { - if ($key == $user->sign_num) { + if ($key == $user->sign_num || ($user->sign_num > 6 && $key == 6)) { $sign_num = $item['sign_num']; break; } diff --git a/template/uni-app/pages/users/user_sgin/index.vue b/template/uni-app/pages/users/user_sgin/index.vue index f77c0c695..2e074e51e 100644 --- a/template/uni-app/pages/users/user_sgin/index.vue +++ b/template/uni-app/pages/users/user_sgin/index.vue @@ -27,7 +27,7 @@ {{(item.day==$t(`第七天`) || item.day==$t(`第7天`))?$t(`奖励`):$t(item.day)}} + :class="(index + 1 === signSystemList.length ? 'venusSelect' : '') + ' ' +(sign_index >= index + 1 ? 'venusSelect' : '')"> +{{item.sign_num}}