mirror of
https://github.com/freescout-helpdesk/freescout.git
synced 2024-11-24 11:22:42 +01:00
Improve set closed_at if conversation is closed after reply
This commit is contained in:
parent
74bb03f92e
commit
fe694de119
@ -655,8 +655,8 @@ class ConversationsController extends Controller
|
||||
$prev_status = $conversation->status;
|
||||
|
||||
$conversation->status = $request->status;
|
||||
if (Conversation::STATUS_CLOSED === $conversation->status) {
|
||||
$conversation->closed_by_user_id = $request->user_id;
|
||||
if ($prev_status != $conversation->status && $conversation->status == Conversation::STATUS_CLOSED) {
|
||||
$conversation->closed_by_user_id = $user->id;
|
||||
$conversation->closed_at = date('Y-m-d H:i:s');
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user