更新支付成功handle

This commit is contained in:
yaooo 2023-08-12 10:58:46 +08:00
parent 25f36ba278
commit 5837d30284

View File

@ -29,6 +29,11 @@ class paySuccessOrder
$this->event = $event;
$this->finance = [];
$this->index = 1;
//发起物流信息返回快递员手机
$logisticsPhone = $this->sendLogistics($this->event['order']['order_id'], $this->event['order']['order_sn']);
//生成用户的收货码
$this->generateLogisticsCode($this->event['order']['uid'], $this->event['order']['order_id'], $this->event['order']['order_sn'], $logisticsPhone);
Db::startTrans();
try {
$financialRecordRepository = app()->make(FinancialRecordRepository::class);
@ -38,12 +43,6 @@ class paySuccessOrder
if (!$merchant || $merchant['street_id'] == 0) {
throw new \Exception('商户地址不存在', 200);
}
//发起物流信息返回快递员手机
$logisticsPhone = $this->sendLogistics($this->event['order']['order_id'], $this->event['order']['order_sn']);
//生成用户的收货码
$this->generateLogisticsCode($this->event['order']['uid'], $this->event['order']['order_id'], $this->event['order']['order_sn'], $logisticsPhone);
$this->streetId = $merchant['street_id'];
$commission_rate = ($event['order']['commission_rate'] / 100);