更新金额
This commit is contained in:
parent
58ee9d16e3
commit
0204f78ee0
@ -293,22 +293,11 @@ class StoreOtherOrderRepository extends BaseRepository
|
|||||||
'mer_id' => $order->mer_id,
|
'mer_id' => $order->mer_id,
|
||||||
'financial_record_sn' => $financeSn . ($i++)
|
'financial_record_sn' => $financeSn . ($i++)
|
||||||
];
|
];
|
||||||
$_payPrice = bcadd($_payPrice, $order->platform_coupon_price, 2);
|
// $_payPrice = bcadd($_payPrice, $order->platform_coupon_price, 2);
|
||||||
}
|
}
|
||||||
if (!$is_combine) {
|
// if (!$is_combine) {
|
||||||
app()->make(MerchantRepository::class)->addLockMoney($order->mer_id, 'order', $order->order_id, $_payPrice);
|
// app()->make(MerchantRepository::class)->addLockMoney($order->mer_id, 'order', $order->order_id, $_payPrice);
|
||||||
}
|
// }
|
||||||
}
|
|
||||||
if ($is_combine) {
|
|
||||||
$profitsharing[] = [
|
|
||||||
'profitsharing_sn' => $storeOrderProfitsharingRepository->getOrderSn(),
|
|
||||||
'order_id' => $order->order_id,
|
|
||||||
'transaction_id' => $order->transaction_id ?? '',
|
|
||||||
'mer_id' => $order->mer_id,
|
|
||||||
'profitsharing_price' => $order->pay_price,
|
|
||||||
'profitsharing_mer_price' => $_payPrice,
|
|
||||||
'type' => $storeOrderProfitsharingRepository::PROFITSHARING_TYPE_ORDER,
|
|
||||||
];
|
|
||||||
}
|
}
|
||||||
$userMerchantRepository->updatePayTime($uid, $order->mer_id, $order->pay_price);
|
$userMerchantRepository->updatePayTime($uid, $order->mer_id, $order->pay_price);
|
||||||
SwooleTaskService::merchant('notice', [
|
SwooleTaskService::merchant('notice', [
|
||||||
@ -339,16 +328,13 @@ class StoreOtherOrderRepository extends BaseRepository
|
|||||||
}
|
}
|
||||||
|
|
||||||
$this->giveIntegral($groupOrder);
|
$this->giveIntegral($groupOrder);
|
||||||
if (count($profitsharing)) {
|
|
||||||
$storeOrderProfitsharingRepository->insertAll($profitsharing);
|
|
||||||
}
|
|
||||||
$financialRecordRepository->insertAll($finance);
|
$financialRecordRepository->insertAll($finance);
|
||||||
$storeOrderStatusRepository->batchCreateLog($orderStatus);
|
$storeOrderStatusRepository->batchCreateLog($orderStatus);
|
||||||
$groupOrder->save();
|
$groupOrder->save();
|
||||||
Db::commit();
|
Db::commit();
|
||||||
return true;
|
return true;
|
||||||
} catch (\Exception $e) {
|
} catch (\Exception $e) {
|
||||||
halt($e->getMessage());
|
Log::error('财务点击支付失败'.$e->getMessage());
|
||||||
// 回滚事务
|
// 回滚事务
|
||||||
Db::rollback();
|
Db::rollback();
|
||||||
return false;
|
return false;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user