Merge branch 'hotfix/ticket' into feature/ticket0807
This commit is contained in:
@@ -44,6 +44,15 @@ class TicketService
|
||||
if(!empty($attachment)){
|
||||
(new AttachmentLogic())->adds($attachment, $result->id, $data['user_id']);
|
||||
}
|
||||
|
||||
$cleanContent = trim(preg_replace('/\s+/', ' ', strip_tags($data['content'] ?? '')));
|
||||
$conversation = [
|
||||
'ticket_id' => $result->id,
|
||||
'content' => $cleanContent,
|
||||
'user_id' => $data['user_id'],
|
||||
];
|
||||
(new ConversationService())->add($conversation);
|
||||
|
||||
return $result;
|
||||
} catch (\Throwable $e) {
|
||||
Db::rollback();
|
||||
|
||||
Reference in New Issue
Block a user