feat: ✨ Reopen tickets
This commit is contained in:
parent
8c2289ed74
commit
af5d28e2a5
6 changed files with 141 additions and 85 deletions
|
@ -33,9 +33,14 @@ class TicketsController extends Controller
|
||||||
return view('moderator.ticket.show', compact('ticket', 'ticketcategory', 'ticketcomments', 'server'));
|
return view('moderator.ticket.show', compact('ticket', 'ticketcategory', 'ticketcomments', 'server'));
|
||||||
}
|
}
|
||||||
|
|
||||||
public function close($ticket_id)
|
public function changeStatus($ticket_id)
|
||||||
{
|
{
|
||||||
$ticket = Ticket::where('ticket_id', $ticket_id)->firstOrFail();
|
$ticket = Ticket::where('ticket_id', $ticket_id)->firstOrFail();
|
||||||
|
if($ticket->status == "Closed"){
|
||||||
|
$ticket->status = "Reopened";
|
||||||
|
$ticket->save();
|
||||||
|
return redirect()->back()->with('success', __('A ticket has been reopened, ID: #') . $ticket->ticket_id);
|
||||||
|
}
|
||||||
$ticket->status = 'Closed';
|
$ticket->status = 'Closed';
|
||||||
$ticket->save();
|
$ticket->save();
|
||||||
$ticketOwner = $ticket->user;
|
$ticketOwner = $ticket->user;
|
||||||
|
@ -85,12 +90,16 @@ class TicketsController extends Controller
|
||||||
return '<a href="'.route('admin.users.show', $tickets->user->id).'">'.$tickets->user->name.'</a>';
|
return '<a href="'.route('admin.users.show', $tickets->user->id).'">'.$tickets->user->name.'</a>';
|
||||||
})
|
})
|
||||||
->addColumn('actions', function (Ticket $tickets) {
|
->addColumn('actions', function (Ticket $tickets) {
|
||||||
|
$statusButtonColor = ($tickets->status == "Closed") ? 'btn-success' : 'btn-warning';
|
||||||
|
$statusButtonIcon = ($tickets->status == "Closed") ? 'fa-redo' : 'fa-times';
|
||||||
|
$statusButtonText = ($tickets->status == "Closed") ? __('Reopen') : __('Close');
|
||||||
|
|
||||||
return '
|
return '
|
||||||
<a data-content="'.__('View').'" data-toggle="popover" data-trigger="hover" data-placement="top" href="'.route('moderator.ticket.show', ['ticket_id' => $tickets->ticket_id]).'" class="btn btn-sm text-white btn-info mr-1"><i class="fas fa-eye"></i></a>
|
<a data-content="'.__('View').'" data-toggle="popover" data-trigger="hover" data-placement="top" href="'.route('moderator.ticket.show', ['ticket_id' => $tickets->ticket_id]).'" class="btn btn-sm text-white btn-info mr-1"><i class="fas fa-eye"></i></a>
|
||||||
<form class="d-inline" method="post" action="'.route('moderator.ticket.close', ['ticket_id' => $tickets->ticket_id]).'">
|
<form class="d-inline" method="post" action="'.route('moderator.ticket.changeStatus', ['ticket_id' => $tickets->ticket_id]).'">
|
||||||
'.csrf_field().'
|
'.csrf_field().'
|
||||||
'.method_field('POST').'
|
'.method_field('POST').'
|
||||||
<button data-content="'.__('Close').'" data-toggle="popover" data-trigger="hover" data-placement="top" class="btn btn-sm text-white btn-warning mr-1"><i class="fas fa-times"></i></button>
|
<button data-content="'.__($statusButtonText).'" data-toggle="popover" data-trigger="hover" data-placement="top" class="btn btn-sm text-white '.$statusButtonColor.' mr-1"><i class="fas '.$statusButtonIcon.'"></i></button>
|
||||||
</form>
|
</form>
|
||||||
<form class="d-inline" method="post" action="'.route('moderator.ticket.delete', ['ticket_id' => $tickets->ticket_id]).'">
|
<form class="d-inline" method="post" action="'.route('moderator.ticket.delete', ['ticket_id' => $tickets->ticket_id]).'">
|
||||||
'.csrf_field().'
|
'.csrf_field().'
|
||||||
|
@ -101,6 +110,7 @@ class TicketsController extends Controller
|
||||||
})
|
})
|
||||||
->editColumn('status', function (Ticket $tickets) {
|
->editColumn('status', function (Ticket $tickets) {
|
||||||
switch ($tickets->status) {
|
switch ($tickets->status) {
|
||||||
|
case 'Reopened':
|
||||||
case 'Open':
|
case 'Open':
|
||||||
$badgeColor = 'badge-success';
|
$badgeColor = 'badge-success';
|
||||||
break;
|
break;
|
||||||
|
|
|
@ -104,9 +104,14 @@ class TicketsController extends Controller
|
||||||
|
|
||||||
return redirect()->back()->with('success', __('Your comment has been submitted'));
|
return redirect()->back()->with('success', __('Your comment has been submitted'));
|
||||||
}
|
}
|
||||||
public function close($ticket_id)
|
public function changeStatus($ticket_id)
|
||||||
{
|
{
|
||||||
$ticket = Ticket::where('user_id', Auth::user()->id)->where("ticket_id", $ticket_id)->firstOrFail();
|
$ticket = Ticket::where('user_id', Auth::user()->id)->where("ticket_id", $ticket_id)->firstOrFail();
|
||||||
|
if($ticket->status == "Closed"){
|
||||||
|
$ticket->status = "Reopened";
|
||||||
|
$ticket->save();
|
||||||
|
return redirect()->back()->with('success', __('A ticket has been reopened, ID: #') . $ticket->ticket_id);
|
||||||
|
}
|
||||||
$ticket->status = "Closed";
|
$ticket->status = "Closed";
|
||||||
$ticket->save();
|
$ticket->save();
|
||||||
return redirect()->back()->with('success', __('A ticket has been closed, ID: #') . $ticket->ticket_id);
|
return redirect()->back()->with('success', __('A ticket has been closed, ID: #') . $ticket->ticket_id);
|
||||||
|
@ -125,6 +130,7 @@ class TicketsController extends Controller
|
||||||
})
|
})
|
||||||
->editColumn('status', function (Ticket $tickets) {
|
->editColumn('status', function (Ticket $tickets) {
|
||||||
switch ($tickets->status) {
|
switch ($tickets->status) {
|
||||||
|
case 'Reopened':
|
||||||
case 'Open':
|
case 'Open':
|
||||||
$badgeColor = 'badge-success';
|
$badgeColor = 'badge-success';
|
||||||
break;
|
break;
|
||||||
|
@ -149,12 +155,16 @@ class TicketsController extends Controller
|
||||||
'raw' => $tickets->updated_at ? strtotime($tickets->updated_at) : ''];
|
'raw' => $tickets->updated_at ? strtotime($tickets->updated_at) : ''];
|
||||||
})
|
})
|
||||||
->addColumn('actions', function (Ticket $tickets) {
|
->addColumn('actions', function (Ticket $tickets) {
|
||||||
|
$statusButtonColor = ($tickets->status == "Closed") ? 'btn-success' : 'btn-warning';
|
||||||
|
$statusButtonIcon = ($tickets->status == "Closed") ? 'fa-redo' : 'fa-times';
|
||||||
|
$statusButtonText = ($tickets->status == "Closed") ? __('Reopen') : __('Close');
|
||||||
|
|
||||||
return '
|
return '
|
||||||
<a data-content="'.__('View').'" data-toggle="popover" data-trigger="hover" data-placement="top" href="'.route('ticket.show', ['ticket_id' => $tickets->ticket_id]).'" class="btn btn-sm text-white btn-info mr-1"><i class="fas fa-eye"></i></a>
|
<a data-content="'.__('View').'" data-toggle="popover" data-trigger="hover" data-placement="top" href="'.route('ticket.show', ['ticket_id' => $tickets->ticket_id]).'" class="btn btn-sm text-white btn-info mr-1"><i class="fas fa-eye"></i></a>
|
||||||
<form class="d-inline" method="post" action="'.route('ticket.close', ['ticket_id' => $tickets->ticket_id]).'">
|
<form class="d-inline" method="post" action="'.route('ticket.changeStatus', ['ticket_id' => $tickets->ticket_id]).'">
|
||||||
'.csrf_field().'
|
'.csrf_field().'
|
||||||
'.method_field('POST').'
|
'.method_field('POST').'
|
||||||
<button data-content="'.__('Close').'" data-toggle="popover" data-trigger="hover" data-placement="top" class="btn btn-sm text-white btn-warning mr-1"><i class="fas fa-times"></i></button>
|
<button data-content="'.__($statusButtonText).'" data-toggle="popover" data-trigger="hover" data-placement="top" class="btn btn-sm text-white '.$statusButtonColor.' mr-1"><i class="fas '.$statusButtonIcon.'"></i></button>
|
||||||
</form>
|
</form>
|
||||||
|
|
||||||
</form>
|
</form>
|
||||||
|
|
|
@ -113,7 +113,7 @@ Route::middleware(['auth', 'checkSuspended'])->group(function () {
|
||||||
Route::post('ticket/new', [TicketsController::class, 'store'])->middleware(['throttle:ticket-new'])->name('ticket.new.store');
|
Route::post('ticket/new', [TicketsController::class, 'store'])->middleware(['throttle:ticket-new'])->name('ticket.new.store');
|
||||||
Route::get('ticket/show/{ticket_id}', [TicketsController::class, 'show'])->name('ticket.show');
|
Route::get('ticket/show/{ticket_id}', [TicketsController::class, 'show'])->name('ticket.show');
|
||||||
Route::post('ticket/reply', [TicketsController::class, 'reply'])->middleware(['throttle:ticket-reply'])->name('ticket.reply');
|
Route::post('ticket/reply', [TicketsController::class, 'reply'])->middleware(['throttle:ticket-reply'])->name('ticket.reply');
|
||||||
Route::post('ticket/close/{ticket_id}', [TicketsController::class, 'close'])->name('ticket.close');
|
Route::post('ticket/status/{ticket_id}', [TicketsController::class, 'changeStatus'])->name('ticket.changeStatus');
|
||||||
}
|
}
|
||||||
|
|
||||||
//admin
|
//admin
|
||||||
|
@ -211,7 +211,7 @@ Route::middleware(['auth', 'checkSuspended'])->group(function () {
|
||||||
Route::get('ticket/datatable', [ModTicketsController::class, 'datatable'])->name('ticket.datatable');
|
Route::get('ticket/datatable', [ModTicketsController::class, 'datatable'])->name('ticket.datatable');
|
||||||
Route::get('ticket/show/{ticket_id}', [ModTicketsController::class, 'show'])->name('ticket.show');
|
Route::get('ticket/show/{ticket_id}', [ModTicketsController::class, 'show'])->name('ticket.show');
|
||||||
Route::post('ticket/reply', [ModTicketsController::class, 'reply'])->name('ticket.reply');
|
Route::post('ticket/reply', [ModTicketsController::class, 'reply'])->name('ticket.reply');
|
||||||
Route::post('ticket/close/{ticket_id}', [ModTicketsController::class, 'close'])->name('ticket.close');
|
Route::post('ticket/status/{ticket_id}', [ModTicketsController::class, 'changeStatus'])->name('ticket.changeStatus');
|
||||||
Route::post('ticket/delete/{ticket_id}', [ModTicketsController::class, 'delete'])->name('ticket.delete');
|
Route::post('ticket/delete/{ticket_id}', [ModTicketsController::class, 'delete'])->name('ticket.delete');
|
||||||
//ticket moderation blacklist
|
//ticket moderation blacklist
|
||||||
Route::get('ticket/blacklist', [ModTicketsController::class, 'blacklist'])->name('ticket.blacklist');
|
Route::get('ticket/blacklist', [ModTicketsController::class, 'blacklist'])->name('ticket.blacklist');
|
||||||
|
|
|
@ -44,6 +44,9 @@
|
||||||
@case("Open")
|
@case("Open")
|
||||||
<span class="badge badge-success">{{__("Open")}}</span>
|
<span class="badge badge-success">{{__("Open")}}</span>
|
||||||
@break
|
@break
|
||||||
|
@case("Reopened")
|
||||||
|
<span class="badge badge-success">{{__("Reopened")}}</span>
|
||||||
|
@break
|
||||||
@case("Closed")
|
@case("Closed")
|
||||||
<span class="badge badge-danger">{{__("Closed")}}</span>
|
<span class="badge badge-danger">{{__("Closed")}}</span>
|
||||||
@break
|
@break
|
||||||
|
@ -69,13 +72,27 @@
|
||||||
@endswitch
|
@endswitch
|
||||||
</p>
|
</p>
|
||||||
<p><b>{{__("Created on")}}:</b> {{ $ticket->created_at->diffForHumans() }}</p>
|
<p><b>{{__("Created on")}}:</b> {{ $ticket->created_at->diffForHumans() }}</p>
|
||||||
@if($ticket->status!='Closed')
|
@if($ticket->status=='Closed')
|
||||||
<form class="d-inline" method="post" action="{{route('moderator.ticket.close', ['ticket_id' => $ticket->ticket_id ])}}">
|
<form class="d-inline" method="post"
|
||||||
{{csrf_field()}}
|
action="{{route('moderator.ticket.changeStatus', ['ticket_id' => $ticket->ticket_id ])}}">
|
||||||
{{method_field("POST") }}
|
{{csrf_field()}}
|
||||||
<button data-content="{{__("Close")}}" data-toggle="popover" data-trigger="hover" data-placement="top" class="btn btn-sm text-white btn-warning mr-1"><i class="fas fa-times"></i>{{__("Close")}}</button>
|
{{method_field("POST") }}
|
||||||
</form>
|
<button data-content="{{__("Reopen")}}" data-toggle="popover"
|
||||||
@endif
|
data-trigger="hover" data-placement="top"
|
||||||
|
class="btn btn-sm text-white btn-success mr-1"><i
|
||||||
|
class="fas fa-redo"></i>{{__("Reopen")}}</button>
|
||||||
|
</form>
|
||||||
|
@else
|
||||||
|
<form class="d-inline" method="post"
|
||||||
|
action="{{route('moderator.ticket.changeStatus', ['ticket_id' => $ticket->ticket_id ])}}">
|
||||||
|
{{csrf_field()}}
|
||||||
|
{{method_field("POST") }}
|
||||||
|
<button data-content="{{__("Close")}}" data-toggle="popover"
|
||||||
|
data-trigger="hover" data-placement="top"
|
||||||
|
class="btn btn-sm text-white btn-warning mr-1"><i
|
||||||
|
class="fas fa-times"></i>{{__("Close")}}</button>
|
||||||
|
</form>
|
||||||
|
@endif
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
@ -36,7 +36,7 @@
|
||||||
|
|
||||||
<div class="card">
|
<div class="card">
|
||||||
<div class="card-header">
|
<div class="card-header">
|
||||||
<h5 class="card-title"><i class="fa fa-coins mr-2"></i>{{ config('app.name', 'Controlpanel.gg') }} Store</h5>
|
<h5 class="card-title"><i class="fa fa-coins mr-2"></i>{{ CREDITS_DISPLAY_NAME }}</h5>
|
||||||
</div>
|
</div>
|
||||||
<div class="card-body">
|
<div class="card-body">
|
||||||
<table class="table table-striped table-responsive-sm">
|
<table class="table table-striped table-responsive-sm">
|
||||||
|
|
|
@ -35,43 +35,58 @@
|
||||||
<div class="card-body">
|
<div class="card-body">
|
||||||
<div class="ticket-info">
|
<div class="ticket-info">
|
||||||
@if(!empty($server))
|
@if(!empty($server))
|
||||||
<p><b>{{__("Server")}}:</b> <a href="{{ config('SETTINGS::SYSTEM:PTERODACTYL:URL') }}/server/{{ $server->identifier }}" target="__blank">{{ $server->name }} </a></p>
|
<p><b>{{__("Server")}}:</b> <a
|
||||||
|
href="{{ config('SETTINGS::SYSTEM:PTERODACTYL:URL') }}/server/{{ $server->identifier }}"
|
||||||
|
target="__blank">{{ $server->name }} </a></p>
|
||||||
@endif
|
@endif
|
||||||
<p><b>{{__("Title")}}:</b> {{ $ticket->title }}</p>
|
<p><b>{{__("Title")}}:</b> {{ $ticket->title }}</p>
|
||||||
<p><b>{{__("Category")}}:</b> {{ $ticketcategory->name }}</p>
|
<p><b>{{__("Category")}}:</b> {{ $ticketcategory->name }}</p>
|
||||||
<p><b>{{__("Status")}}:</b>
|
<p><b>{{__("Status")}}:</b>
|
||||||
@switch($ticket->status)
|
@switch($ticket->status)
|
||||||
@case("Open")
|
@case("Open")
|
||||||
<span class="badge badge-success">{{__("Open")}}</span>
|
<span class="badge badge-success">{{__("Open")}}</span>
|
||||||
@break
|
@break
|
||||||
@case("Closed")
|
@case("Reopened")
|
||||||
<span class="badge badge-danger">{{__("Closed")}}</span>
|
<span class="badge badge-success">{{__("Reopened")}}</span>
|
||||||
@break
|
@break
|
||||||
@case("Answered")
|
@case("Closed")
|
||||||
<span class="badge badge-info">{{__("Answered")}}</span>
|
<span class="badge badge-danger">{{__("Closed")}}</span>
|
||||||
@break
|
@break
|
||||||
@case("Client Reply")
|
@case("Answered")
|
||||||
<span class="badge badge-warning">{{__("Client Reply")}}</span>
|
<span class="badge badge-info">{{__("Answered")}}</span>
|
||||||
@break
|
@break
|
||||||
@endswitch
|
@case("Client Reply")
|
||||||
</p>
|
<span class="badge badge-warning">{{__("Client Reply")}}</span>
|
||||||
<p><b>Priority:</b>
|
@break
|
||||||
@switch($ticket->priority)
|
@endswitch
|
||||||
@case("Low")
|
</p>
|
||||||
<span class="badge badge-success">{{__("Low")}}</span>
|
<p><b>Priority:</b>
|
||||||
@break
|
@switch($ticket->priority)
|
||||||
@case("Medium")
|
@case("Low")
|
||||||
<span class="badge badge-warning">{{__("Medium")}}</span>
|
<span class="badge badge-success">{{__("Low")}}</span>
|
||||||
@break
|
@break
|
||||||
@case("High")
|
@case("Medium")
|
||||||
<span class="badge badge-danger">{{__("High")}}</span>
|
<span class="badge badge-warning">{{__("Medium")}}</span>
|
||||||
@break
|
@break
|
||||||
@endswitch
|
@case("High")
|
||||||
</p>
|
<span class="badge badge-danger">{{__("High")}}</span>
|
||||||
|
@break
|
||||||
|
@endswitch
|
||||||
|
</p>
|
||||||
<p><b>{{__("Created on")}}:</b> {{ $ticket->created_at->diffForHumans() }}</p>
|
<p><b>{{__("Created on")}}:</b> {{ $ticket->created_at->diffForHumans() }}</p>
|
||||||
@if($ticket->status!='Closed')
|
@if($ticket->status=='Closed')
|
||||||
<form class="d-inline" method="post"
|
<form class="d-inline" method="post"
|
||||||
action="{{route('ticket.close', ['ticket_id' => $ticket->ticket_id ])}}">
|
action="{{route('ticket.changeStatus', ['ticket_id' => $ticket->ticket_id ])}}">
|
||||||
|
{{csrf_field()}}
|
||||||
|
{{method_field("POST") }}
|
||||||
|
<button data-content="{{__("Reopen")}}" data-toggle="popover"
|
||||||
|
data-trigger="hover" data-placement="top"
|
||||||
|
class="btn btn-sm text-white btn-success mr-1"><i
|
||||||
|
class="fas fa-redo"></i>{{__("Reopen")}}</button>
|
||||||
|
</form>
|
||||||
|
@else
|
||||||
|
<form class="d-inline" method="post"
|
||||||
|
action="{{route('ticket.changeStatus', ['ticket_id' => $ticket->ticket_id ])}}">
|
||||||
{{csrf_field()}}
|
{{csrf_field()}}
|
||||||
{{method_field("POST") }}
|
{{method_field("POST") }}
|
||||||
<button data-content="{{__("Close")}}" data-toggle="popover"
|
<button data-content="{{__("Close")}}" data-toggle="popover"
|
||||||
|
@ -96,56 +111,60 @@
|
||||||
<div class="card-header">
|
<div class="card-header">
|
||||||
<div class="d-flex justify-content-between">
|
<div class="d-flex justify-content-between">
|
||||||
<h5 class="card-title"><img
|
<h5 class="card-title"><img
|
||||||
src="https://www.gravatar.com/avatar/{{ md5(strtolower($ticket->user->email)) }}?s=25"
|
src="https://www.gravatar.com/avatar/{{ md5(strtolower($ticket->user->email)) }}?s=25"
|
||||||
class="user-image" alt="User Image">
|
class="user-image" alt="User Image">
|
||||||
<a href="/admin/users/{{$ticket->user->id}}">{{ $ticket->user->name }} </a>
|
<a href="/admin/users/{{$ticket->user->id}}">{{ $ticket->user->name }} </a>
|
||||||
@if($ticket->user->role === "member")
|
@if($ticket->user->role === "member")
|
||||||
<span class="badge badge-secondary"> Member </span>
|
<span class="badge badge-secondary"> Member </span>
|
||||||
@elseif ($ticket->user->role === "client")
|
@elseif ($ticket->user->role === "client")
|
||||||
<span class="badge badge-success"> Client </span>
|
<span class="badge badge-success"> Client </span>
|
||||||
@elseif ($ticket->user->role === "moderator")
|
@elseif ($ticket->user->role === "moderator")
|
||||||
<span class="badge badge-info"> Moderator </span>
|
<span class="badge badge-info"> Moderator </span>
|
||||||
@elseif ($ticket->user->role === "admin")
|
@elseif ($ticket->user->role === "admin")
|
||||||
<span class="badge badge-danger"> Admin </span>
|
<span class="badge badge-danger"> Admin </span>
|
||||||
@endif
|
@endif
|
||||||
</h5>
|
</h5>
|
||||||
<span class="badge badge-primary">{{ $ticket->created_at->diffForHumans() }}</span>
|
<span
|
||||||
|
class="badge badge-primary">{{ $ticket->created_at->diffForHumans() }}</span>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="card-body" style="white-space:pre-wrap">{{ $ticket->message }}</div>
|
<div class="card-body" style="white-space:pre-wrap">{{ $ticket->message }}</div>
|
||||||
</div>
|
</div>
|
||||||
@foreach ($ticketcomments as $ticketcomment)
|
@foreach ($ticketcomments as $ticketcomment)
|
||||||
<div class="card">
|
<div class="card">
|
||||||
<div class="card-header">
|
<div class="card-header">
|
||||||
<div class="d-flex justify-content-between">
|
<div class="d-flex justify-content-between">
|
||||||
<h5 class="card-title"><img
|
<h5 class="card-title"><img
|
||||||
src="https://www.gravatar.com/avatar/{{ md5(strtolower($ticketcomment->user->email)) }}?s=25"
|
src="https://www.gravatar.com/avatar/{{ md5(strtolower($ticketcomment->user->email)) }}?s=25"
|
||||||
class="user-image" alt="User Image">
|
class="user-image" alt="User Image">
|
||||||
<a href="/admin/users/{{$ticketcomment->user->id}}">{{ $ticketcomment->user->name }}</a>
|
<a href="/admin/users/{{$ticketcomment->user->id}}">{{ $ticketcomment->user->name }}</a>
|
||||||
@if($ticketcomment->user->role === "member")
|
@if($ticketcomment->user->role === "member")
|
||||||
<span class="badge badge-secondary"> Member </span>
|
<span class="badge badge-secondary"> Member </span>
|
||||||
@elseif ($ticketcomment->user->role === "client")
|
@elseif ($ticketcomment->user->role === "client")
|
||||||
<span class="badge badge-success"> Client </span>
|
<span class="badge badge-success"> Client </span>
|
||||||
@elseif ($ticketcomment->user->role === "moderator")
|
@elseif ($ticketcomment->user->role === "moderator")
|
||||||
<span class="badge badge-info"> Moderator </span>
|
<span class="badge badge-info"> Moderator </span>
|
||||||
@elseif ($ticketcomment->user->role === "admin")
|
@elseif ($ticketcomment->user->role === "admin")
|
||||||
<span class="badge badge-danger"> Admin </span>
|
<span class="badge badge-danger"> Admin </span>
|
||||||
@endif
|
@endif
|
||||||
</h5>
|
</h5>
|
||||||
<span class="badge badge-primary">{{ $ticketcomment->created_at->diffForHumans() }}</span>
|
<span
|
||||||
|
class="badge badge-primary">{{ $ticketcomment->created_at->diffForHumans() }}</span>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
<div class="card-body"
|
||||||
|
style="white-space:pre-wrap">{{ $ticketcomment->ticketcomment }}</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="card-body" style="white-space:pre-wrap">{{ $ticketcomment->ticketcomment }}</div>
|
|
||||||
</div>
|
|
||||||
@endforeach
|
@endforeach
|
||||||
<div class="comment-form">
|
<div class="comment-form">
|
||||||
<form action="{{ route('ticket.reply')}}" method="POST" class="form reply-form">
|
<form action="{{ route('ticket.reply')}}" method="POST" class="form reply-form">
|
||||||
{!! csrf_field() !!}
|
{!! csrf_field() !!}
|
||||||
<input type="hidden" name="ticket_id" value="{{ $ticket->id }}">
|
<input type="hidden" name="ticket_id" value="{{ $ticket->id }}">
|
||||||
<div class="form-group{{ $errors->has('ticketcomment') ? ' has-error' : '' }}">
|
<div class="form-group{{ $errors->has('ticketcomment') ? ' has-error' : '' }}">
|
||||||
<textarea rows="10" id="ticketcomment" class="form-control" name="ticketcomment"></textarea>
|
<textarea rows="10" id="ticketcomment" class="form-control"
|
||||||
|
name="ticketcomment"></textarea>
|
||||||
@if ($errors->has('ticketcomment'))
|
@if ($errors->has('ticketcomment'))
|
||||||
<span class="help-block">
|
<span class="help-block">
|
||||||
<strong>{{ $errors->first('ticketcomment') }}</strong>
|
<strong>{{ $errors->first('ticketcomment') }}</strong>
|
||||||
</span>
|
</span>
|
||||||
@endif
|
@endif
|
||||||
|
|
Loading…
Reference in a new issue