盲盒转盘优化-调试-加日志监控

This commit is contained in:
2025-10-25 10:56:30 +08:00
parent b7302fa213
commit 8ad606a8dd

View File

@@ -610,7 +610,7 @@ class BlindBoxTurntableGiftDrawWorld extends Model
// 检查库存是否足够
if ($giftBagDetail['remaining_number'] < $count) {
$this->redis->setex('blind_box_draw_world_errors_' . date('Y-m-d-H-i-s'), 86400 * 7, "礼物库存不足 礼物ID".$giftId.' 数量:'.$count.' 预处理结果:'.json_encode($precomputedResults));
$this->redis->setex('blind_box_draw_world_errors_' . date('Y-m-d-H-i-s'), 86400 * 7, "礼物库存不足 礼物ID".$giftId.' 数量:'.$count.' 预处理结果:'.json_encode($precomputedResults).'礼物数量详情:'.json_encode($inventoryUpdates));
throw new \Exception("礼物库存不足ID: " . $giftId);
}
// 执行更新