Bug-fix-patch4

# client close ticket thread is not internal
# change lenght of titcket title in cleint ticket list page
# client side ticket attachment issue fixed
This commit is contained in:
Manish Verma
2016-11-28 16:41:55 +05:30
parent fd8d9085c2
commit 6f7ee1569c
3 changed files with 106 additions and 110 deletions

View File

@@ -1246,6 +1246,11 @@ class TicketController extends Controller
if ($ticket_status == null) {
return redirect()->route('unauth');
}
if(\Auth::user()->role == 'user') {
$is_internal = 0;
} else {
$is_internal = 1;
}
$ticket_status->status = 3;
$ticket_status->closed = 1;
$ticket_status->closed_at = date('Y-m-d H:i:s');
@@ -1256,7 +1261,7 @@ class TicketController extends Controller
$thread = new Ticket_Thread();
$thread->ticket_id = $ticket_status->id;
$thread->user_id = Auth::user()->id;
$thread->is_internal = 1;
$thread->is_internal = $is_internal;
$thread->body = $ticket_status_message->message.' '.Auth::user()->first_name.' '.Auth::user()->last_name;
$thread->save();