diff --git a/app/queue/redis/InquiryToCrmNew.php b/app/queue/redis/InquiryToCrmNew.php index 420fe95..a350c7e 100644 --- a/app/queue/redis/InquiryToCrmNew.php +++ b/app/queue/redis/InquiryToCrmNew.php @@ -61,7 +61,7 @@ class InquiryToCrmNew implements Consumer } } - public function pushWs($title, $content, $recipient) + public function pushWs($title, $content, $recipient = []) { $wsdata = [ 'sender_id' => 0, @@ -84,21 +84,21 @@ class InquiryToCrmNew implements Consumer // 消息推送 if ($info->status == 2 && empty($crmCustomerInfo->user_id)) { // $notice = '分配'; - $title = '[询单·分配]新的客户线索【' . $info->order_no . '】,请及时处理'; - $content = '[询单·分配]新的客户线索【' . $info->order_no . '】,请及时处理'; + $title = '[询单·分配] 新的客户线索【' . $info->order_no . '】,请及时处理'; + $content = '[询单·分配] 新的客户线索【' . $info->order_no . '】,请及时处理'; $recipient = [$info->recipient]; $this->pushWs($title, $content, $recipient); } else { if ($info->status == 2 && $crmCustomerInfo->user_id == $info->recipient) { // $notice = '更新'; - $title = '[询单·更新]客户线索' . $info->order_no . '有新的调整,请及时处理'; - $content = '[询单·更新]客户线索' . $info->order_no . '有新的调整,请及时处理'; + $title = '[询单·更新] 客户线索' . $info->order_no . '有新的调整,请及时处理'; + $content = '[询单·更新] 客户线索' . $info->order_no . '有新的调整,请及时处理'; $recipient = [$info->recipient]; $this->pushWs($title, $content, $recipient); } else { // $notice = '重新分配'; - $title = '[询单·分配]新的客户线索【' . $info->order_no . '】,请及时处理'; - $content = '[询单·分配]新的客户线索【' . $info->order_no . '】,请及时处理'; + $title = '[询单·分配] 新的客户线索【' . $info->order_no . '】,请及时处理'; + $content = '[询单·分配] 新的客户线索【' . $info->order_no . '】,请及时处理'; $recipient = [$info->recipient]; $this->pushWs($title, $content, $recipient); } @@ -145,16 +145,16 @@ class InquiryToCrmNew implements Consumer // 消息推送 if ($info->status == 1) { // $notice = '发布'; - $title = '[询单·公海]新的客户线索【' . $info->order_no . '】发布'; - $content = '[询单·公海]新的客户线索【' . $info->order_no . '】发布'; + $title = '[询单·公海] 新的客户线索【' . $info->order_no . '】发布'; + $content = '[询单·公海] 新的客户线索【' . $info->order_no . '】发布'; $recipient = [$info->recipient]; - $this->pushWs($title, $content, $recipient); + $this->pushWs($title, $content); } if ($info->status == 2) { // $notice = '分配'; - $title = '[询单·分配]新的客户线索【' . $info->order_no . '】,请及时处理'; - $content = '[询单·分配]新的客户线索【' . $info->order_no . '】,请及时处理'; + $title = '[询单·分配] 新的客户线索【' . $info->order_no . '】,请及时处理'; + $content = '[询单·分配] 新的客户线索【' . $info->order_no . '】,请及时处理'; $recipient = [$info->recipient]; $this->pushWs($title, $content, $recipient); }