diff --git a/backend/app/service/FeishuNotificationService.php b/backend/app/service/FeishuNotificationService.php index cb3061a..4d3a6bb 100644 --- a/backend/app/service/FeishuNotificationService.php +++ b/backend/app/service/FeishuNotificationService.php @@ -677,6 +677,12 @@ class FeishuNotificationService return true; } + // 获取订单以确定公司ID,设置飞书应用配置 + $order = \app\model\ApprovalOrder::find($orderId); + if ($order && $order->company_id) { + $this->setAppByUser($excludeUserId, $order->company_id); + } + $token = $this->getAccessToken(); $statusText = $status === 'approved' ? '已通过' : '已拒绝'; $statusColor = $status === 'approved' ? 'green' : 'red'; @@ -816,6 +822,12 @@ class FeishuNotificationService return true; } + // 获取订单以确定公司ID,设置飞书应用配置 + $order = \app\model\ApprovalOrder::find($orderId); + if ($order && $order->company_id) { + $this->setAppByUser($excludeUserId, $order->company_id); + } + $token = $this->getAccessToken(); $remainingCount = $totalCount - $approvedCount;