bug-fix-patch-1
# client side close ticket
This commit is contained in:
@@ -1237,10 +1237,6 @@ class TicketController extends Controller
|
|||||||
public function close($id, Tickets $ticket)
|
public function close($id, Tickets $ticket)
|
||||||
{
|
{
|
||||||
$ticket = Tickets::where('id', '=', $id)->first();
|
$ticket = Tickets::where('id', '=', $id)->first();
|
||||||
|
|
||||||
$approval = Approval::where('id', '=', 1)->first();
|
|
||||||
//Admin can close direce
|
|
||||||
if (Auth::user()->role == 'admin') {
|
|
||||||
if (Auth::user()->role == 'user') {
|
if (Auth::user()->role == 'user') {
|
||||||
$ticket_status = $ticket->where('id', '=', $id)->where('user_id', '=', Auth::user()->id)->first();
|
$ticket_status = $ticket->where('id', '=', $id)->where('user_id', '=', Auth::user()->id)->first();
|
||||||
} else {
|
} else {
|
||||||
@@ -1292,7 +1288,6 @@ class TicketController extends Controller
|
|||||||
|
|
||||||
return 'your ticket'.$ticket_status->ticket_number.' has been closed';
|
return 'your ticket'.$ticket_status->ticket_number.' has been closed';
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* function to Ticket resolved.
|
* function to Ticket resolved.
|
||||||
|
Reference in New Issue
Block a user