WIP
parent
85524f5079
commit
78333acf97
|
|
@ -24,7 +24,7 @@ class UserController extends Controller
|
|||
$user = $request->user();
|
||||
|
||||
$dealer = DealerResource::make($user->dealer)->toArray($request);
|
||||
$dealer['current_purchase_amount'] = $calculatePurchaseAmountOfCurrentPeriod->handle($user->dealer);
|
||||
$dealer['current_purchase_amount'] = bcdiv($calculatePurchaseAmountOfCurrentPeriod->handle($user->dealer), '1', 2);
|
||||
|
||||
return response()->json([
|
||||
'phone' => $user->phone,
|
||||
|
|
|
|||
|
|
@ -18,11 +18,11 @@ class DealerResource extends JsonResource
|
|||
'lvl' => $this->lvl,
|
||||
'lvl_name'=> $this->lvl_text,
|
||||
'is_sale' => $this->is_sale,
|
||||
'guanli_values'=> $this->calculate_total_amount, //预计管理津贴
|
||||
'guanli_values'=> bcdiv($this->calculate_total_amount, '1', 2), //预计管理津贴
|
||||
'team_sales_value' => $this->team_sales_value, // 团队业绩
|
||||
'pay_info'=>$this->pay_info ?: null,
|
||||
'can_withdraw'=> $this->canWithdraw(),
|
||||
'total_purchase_amount'=> $this->total_purchase_amount, // 总进货业绩
|
||||
'total_purchase_amount'=> bcdiv($this->total_purchase_amount, '1', 2), // 总进货业绩
|
||||
];
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue