mirror of
https://github.com/v2board/v2board.git
synced 2024-11-10 09:39:10 +08:00
update: commission stats
This commit is contained in:
parent
dc72c6dced
commit
30f0166ed1
@ -53,10 +53,10 @@ class V2boardStatistics extends Command
|
||||
->whereNotIn('status', [0, 2]);
|
||||
$orderCount = $orderBuilder->count();
|
||||
$orderAmount = $orderBuilder->sum('total_amount');
|
||||
$commissionBuilder = Order::where('created_at', '>=', $startAt)
|
||||
$commissionLogBuilder = CommissionLog::where('created_at', '>=', $startAt)
|
||||
->where('created_at', '<', $endAt);
|
||||
$commissionCount = $commissionBuilder->count();
|
||||
$commissionAmount = $commissionBuilder->sum('actual_commission_balance');
|
||||
$commissionCount = $commissionLogBuilder->count();
|
||||
$commissionAmount = $commissionLogBuilder->sum('get_amount');
|
||||
$data = [
|
||||
'order_count' => $orderCount,
|
||||
'order_amount' => $orderAmount,
|
||||
|
Loading…
Reference in New Issue
Block a user