This commit is contained in:
aozhiwei 2024-10-09 11:18:26 +08:00
parent fd644c4bf5
commit e968bf049a
2 changed files with 9 additions and 7 deletions

View File

@ -491,10 +491,11 @@ class ToolsController extends BaseController {
echo $checkSql2; echo $checkSql2;
} }
public function battleBoxDumpToday() public function battleBoxDump()
{ {
$phase = getReqVal('phase', ''); $phase = getReqVal('phase', '');
BattleBoxService::dumpToday($phase); $day = getReqVal('day', '');
BattleBoxService::dump($phase, $day);
} }
} }

View File

@ -115,14 +115,15 @@ class BattleBoxService {
return $boxNum; return $boxNum;
} }
public static function dumpToday($phase) public static function dump($phase, $day)
{ {
$daySeconds = myself()->_getNowDaySeconds() + $day * 3600 * 24;
$data = array( $data = array(
'phase' => $phase, 'phase' => $phase,
'drop_last_time' => self::getDailyPhaseDropLastTime($phase, myself()->_getNowDaySeconds()), 'drop_last_time' => self::getDailyPhaseDropLastTime($phase, $daySeconds),
'drop_curr_total' => self::getDailyPhaseDropTotalNum($phase, myself()->_getNowDaySeconds()), 'drop_curr_total' => self::getDailyPhaseDropTotalNum($phase, $daySeconds),
'alloc_num' => self::getDailyPhaseAllocNum($phase, myself()->_getNowDaySeconds()), 'alloc_num' => self::getDailyPhaseAllocNum($phase, $daySeconds),
'already_alloced_num' => self::getDailyPhaseAlreadyAllocNum($phase, myself()->_getNowDaySeconds()), 'already_alloced_num' => self::getDailyPhaseAlreadyAllocNum($phase, $daySeconds),
); );
myself()->_rspData($data); myself()->_rspData($data);
} }