房间流水统计

This commit is contained in:
2026-01-09 15:10:29 +08:00
parent 42785f219f
commit 55e48b5e13

View File

@@ -559,7 +559,7 @@ class Room extends Model
if($isOwner) {
$total_earning = round($total_amount * $room_user_ratio / $coin_exchange_rate, 4);
}else{
$total_earning = rand(db::name('user_earnings_log')
$total_earning = round(db::name('user_earnings_log')
->where(['user_id' => $userId,'room_id' => $room_id,'change_type' => 19])
->where(['createtime' => ['between', [strtotime($stime), $end_time]]])
->sum('earnings'),4);