工单邮件
This commit is contained in:
@@ -59,21 +59,21 @@ class ConversationService
|
|||||||
'content' => $data['content'],
|
'content' => $data['content'],
|
||||||
'reply' => '',
|
'reply' => '',
|
||||||
];
|
];
|
||||||
|
//$emailDefault = 'app@hnxinyouhe.com'; //公共邮箱
|
||||||
|
$emailDefault = 'tuotuo@hnxinyouhe.com'; //范彩凤
|
||||||
if (empty($conversation)) {
|
if (empty($conversation)) {
|
||||||
//$email = 'app@hnxinyouhe.com'; //公共邮箱
|
$email = $emailDefault;
|
||||||
$email = 'tuotuo@hnxinyouhe.com'; //范彩凤
|
|
||||||
$email = 'beimanr@hnxinyouhe.com'; //范彩凤
|
|
||||||
}else{
|
}else{
|
||||||
$tiket = (new TicketLogic)->find($conversation['ticket_id']);
|
$tiket = (new TicketLogic)->find($conversation['ticket_id']);
|
||||||
if($data['user_id'] != $tiket['user_id']){
|
if($data['user_id'] != $tiket['user_id']){
|
||||||
$email = User::find($tiket['user_id'])->value('email');
|
$email = User::find($tiket['user_id'])->value('email');
|
||||||
}else{
|
}else{
|
||||||
$conversationLast = Conversation::where('user_id', '=', $conversation['user_id'])
|
$conversationLast = Conversation::where('ticket_id', '=', $conversation['ticket_id'])
|
||||||
->where('ticket_id', '=', $conversation['ticket_id'])
|
->where('user_id', '!=', $data['user_id'])
|
||||||
->where('user_id', '!=', $conversation['user_id'])
|
|
||||||
->orderBy('id', 'desc')
|
->orderBy('id', 'desc')
|
||||||
->first();
|
->first();
|
||||||
$email = User::find($conversationLast['user_id'])->value('email','app@hnxinyouhe.com');
|
|
||||||
|
$email = (!empty($conversationLast['user_id']))?User::find($conversationLast['user_id'])->value('email',$emailDefault):$emailDefault;
|
||||||
}
|
}
|
||||||
$notice['content'] = $tiket['content'];
|
$notice['content'] = $tiket['content'];
|
||||||
$notice['reply'] = '<li>最新回复:' . $data['content'] . '</li>';
|
$notice['reply'] = '<li>最新回复:' . $data['content'] . '</li>';
|
||||||
|
|||||||
Reference in New Issue
Block a user