This commit is contained in:
aozhiwei 2022-06-06 13:00:45 +08:00
parent 8e3c235b91
commit 1f0d7a97bf
3 changed files with 5 additions and 4 deletions

View File

@ -174,7 +174,7 @@ class Gun extends BaseModel {
'lock_type' => $lockType,
'unlock_time' => $unlockTime,
'unlock_lefttime' => max(0,
$unlockTime - myself()->_getNowDaySeconds()),
$unlockTime - myself()->_getNowTime()),
'unlock_trade_time' => $row['unlock_trade_time'],
);
$dto['ceg_uplimit'] = FormulaService::getWeaponPvpDailyCegUpLimit($dto);

View File

@ -50,7 +50,7 @@ class Hero extends BaseModel {
$row['hero_uniid'] = $row['idx'];
if ($row['account_id'] != $accountId) {
$openId = phpcommon\extractOpenId($accountId);
if (!NftService::isHeroOwner($opneId, $row['token_id'])) {
if (!NftService::isHeroOwner($openId, $row['token_id'])) {
$row = null;
}
}
@ -120,6 +120,7 @@ class Hero extends BaseModel {
public static function toDto($row)
{
error_log(json_encode($row));
$attr = emptyReplace(json_decode($row['rand_attr'], true), array());
$lockType = 0;
$unlockTime = 0;
@ -163,7 +164,7 @@ class Hero extends BaseModel {
'lock_type' => $lockType,
'unlock_time' => $unlockTime,
'unlock_lefttime' => max(0,
$unlockTime - myself()->_getNowDaySeconds()),
$unlockTime - myself()->_getNowTime()),
'today_get_gold' => $todayGetGold,
'last_get_gold_time' => $lastGetGoldTime,
'today_pve_get_ceg' => $todayPveGetCeg,

View File

@ -600,7 +600,7 @@ class MissionService extends BaseService {
foreach ($this->offerRewartdMission['missions'] as $mission) {
if ($mission['mission_id'] == $missionDto['mission_id']) {
if ($mission['sendtime'] > 0) {
$leftTime = max(0, ($mission['sendtime'] + $missionMeta['time'] + 1000)-myself()->_getNowTime());
$leftTime = max(0, ($mission['sendtime'] + $missionMeta['time'])-myself()->_getNowTime());
$missionDto['lefttime'] = $leftTime;
if ($leftTime <= 0) {
$missionDto['state'] = 0;