fix: 添加事件注册 修改参数问题

This commit is contained in:
Gosowong 2023-05-16 09:43:18 +08:00
parent 37e3344262
commit 956ab1eda1
2 changed files with 9 additions and 6 deletions

View File

@ -39,6 +39,7 @@ return [
'NoticeListener' => [\app\listener\notice\NoticeListener::class], //通知->消息事件
'NotifyListener' => [\app\listener\pay\NotifyListener::class],//支付异步回调
'CrontabListener' => [\app\listener\crontab\SystemCrontabListener::class],//定时任务事件
'OrderShipping' => [\app\listener\order\OrderShippingListener::class],//定时任务事件
],
];

View File

@ -37,17 +37,19 @@ class OrderShippingListener implements ListenerInterface
$orderInfoServices = app()->make(StoreOrderCartInfoServices::class);
$item_desc = $orderInfoServices->getCarIdByProductTitle((int)$order['id'], true);
$shipping_list = [
'item_desc' => $item_desc
['item_desc' => $item_desc]
];
//判断订单物流模式
if ($order['shipping_type'] == 1) {
if ($delivery_type == 1) {
$shipping_list = [
'tracking_no' => $delivery_id ?? '',
'express_company' => $delivery_name ?? '',
'item_desc' => $item_desc,
'contact' => [
'receiver_contact' => $order['user_phone']
[
'tracking_no' => $delivery_id ?? '',
'express_company' => $delivery_name ?? '',
'item_desc' => $item_desc,
'contact' => [
'receiver_contact' => $order['user_phone']
]
]
];
}