|
|
|
@ -108,7 +108,7 @@ class VerificationController extends Controller |
|
|
|
$cost = 0; |
|
|
|
//如果有地接价格 分帐给地接
|
|
|
|
if ($order->guide_price > 0) { |
|
|
|
//$guidePrice = $order->guide_price;
|
|
|
|
$guidePrice = $order->guide_price; |
|
|
|
$cost = bcadd($cost, $order->guide_price, 6); |
|
|
|
//成本价 加上地接价格
|
|
|
|
$statementCreate[] = $service->createByOrder( |
|
|
|
@ -142,10 +142,10 @@ class VerificationController extends Controller |
|
|
|
// $order->id,
|
|
|
|
// StatementTraits::$type[0]
|
|
|
|
// );
|
|
|
|
// $guidePrice = bcsub($order->guide_price, $cutPrice, 6);
|
|
|
|
// $guide = Guide::query()->where('id', $order->guide->id)->lockForUpdate()->first();
|
|
|
|
// $guide->balance = bcadd($guide->balance, $guidePrice, 6);
|
|
|
|
// $guide->save();
|
|
|
|
//$guidePrice = bcsub($order->guide_price, $cutPrice, 6);
|
|
|
|
$guide = Guide::query()->where('id', $order->guide->id)->lockForUpdate()->first(); |
|
|
|
$guide->balance = bcadd($guide->balance, $guidePrice, 6); |
|
|
|
$guide->save(); |
|
|
|
// }
|
|
|
|
//}
|
|
|
|
} |
|
|
|
|