working timers
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
@php
|
||||
use Illuminate\Support\Str;use Modules\Helpdesk\Models\TicketTimeLog;
|
||||
|
||||
use Illuminate\Support\Str;
|
||||
use Modules\Helpdesk\Models\TicketTimeLog;
|
||||
$currentUser = auth()->user();
|
||||
$currentCompany = $currentUser?->company;
|
||||
$canSeeInternalNotes =
|
||||
@@ -9,10 +9,10 @@
|
||||
Str::contains(Str::lower((string) ($currentCompany?->name ?? '')), 'mpba');
|
||||
$visibleCommentCount = $ticket->comments->count();
|
||||
$ticketTimeLogs = TicketTimeLog::query()
|
||||
->with('user')
|
||||
->where('ticket_id', $ticket->getKey())
|
||||
->orderByDesc('started_at')
|
||||
->get();
|
||||
->with('user')
|
||||
->where('ticket_id', $ticket->getKey())
|
||||
->orderByDesc('started_at')
|
||||
->get();
|
||||
@endphp
|
||||
|
||||
<div data-dusk="helpdesk-ticket-show" dusk="helpdesk-ticket-show" class="hd-helpdesk-surface space-y-4">
|
||||
@@ -1205,7 +1205,7 @@
|
||||
</p>
|
||||
</div>
|
||||
@php
|
||||
$timeLogSeconds = (int) ($timeLog->seconds ?? ((int) $timeLog->minutes * 60));
|
||||
$timeLogSeconds = max(0, (int) ($timeLog->seconds ?? ((int) $timeLog->minutes * 60)));
|
||||
@endphp
|
||||
<span class="shrink-0 rounded-lg bg-emerald-600 px-3 py-1.5 text-xs font-black text-white">
|
||||
{{ gmdate('H:i:s', $timeLogSeconds) }}
|
||||
|
||||
Reference in New Issue
Block a user