This commit is contained in:
aozhiwei 2020-03-27 17:39:59 +08:00
parent 929341531e
commit ee8ef29aeb
2 changed files with 7 additions and 3 deletions

View File

@ -124,7 +124,7 @@ class RoleController{
':user_name' => $user_name,
':avatar_url' => $avatar_url,
':create_time' => time(),
':modify_time' => time(),
':modify_time' => 0,
':daily_time' => 0
));
if (!$ret) {

View File

@ -129,11 +129,15 @@ class SignController{
$last_sign_id = $row['sign_id'];
}
}
if ($nowTime - phpcommon\getdayseconds($last_sign_time) > 0) {
$rowuser = $conn->execQueryOne('SELECT modify_time FROM user WHERE accountid=:accountid;',
array(
':accountid' => $account_id
));
if ($nowTime - phpcommon\getdayseconds($rowuser['modify_time']) > 0) {
//每日刷新
$this->updateDaily($account_id);
$this->updateSeasonStatus($account_id);
if (phpcommon\getMondayseconds(time()) - phpcommon\getMondayseconds($last_sign_time) > 0) {
if (phpcommon\getMondayseconds(time()) - phpcommon\getMondayseconds($rowuser['modify_time']) > 0) {
$this->updateWeekReward($account_id);
}
$passed_days = floor(($nowTime - phpcommon\getdayseconds($last_sign_time)) / (3600 * 24));