45 lines
2 KiB
PHP
45 lines
2 KiB
PHP
<div class="timeline">
|
|
@forelse($incident->activities as $activity)
|
|
<div class="timeline-item {{ $activity->type === 'status_change' ? 'timeline-item-secondary' : '' }}">
|
|
<div class="timeline-indicator bg-{{ match($activity->type) {
|
|
'status_change' => 'info',
|
|
'email' => 'primary',
|
|
'call' => 'success',
|
|
'ticket' => 'warning',
|
|
'provider_response' => 'secondary',
|
|
default => 'light border'
|
|
} }}">
|
|
<i class="ion {{ $activity->type_icon }}"></i>
|
|
</div>
|
|
<div class="timeline-content">
|
|
<div class="d-flex justify-content-between align-items-start">
|
|
<div>
|
|
<span class="badge badge-light">{{ $activity->type_label }}</span>
|
|
<strong class="ml-1">{{ $activity->title }}</strong>
|
|
</div>
|
|
<small class="text-muted text-nowrap ml-2">
|
|
{{ $activity->created_at->format('d.m.Y H:i') }}
|
|
— {{ $activity->author }}
|
|
</small>
|
|
</div>
|
|
@if($activity->content)
|
|
<div class="mt-1 text-muted">{{ $activity->content }}</div>
|
|
@endif
|
|
</div>
|
|
</div>
|
|
@empty
|
|
<p class="text-muted">Noch keine Aktivitäten.</p>
|
|
@endforelse
|
|
</div>
|
|
|
|
<style>
|
|
.timeline { position: relative; padding-left: 2.5rem; }
|
|
.timeline::before { content: ''; position: absolute; left: 1rem; top: 0; bottom: 0; width: 2px; background: #e9ecef; }
|
|
.timeline-item { position: relative; margin-bottom: 1.25rem; }
|
|
.timeline-indicator {
|
|
position: absolute; left: -2.5rem; width: 2rem; height: 2rem;
|
|
border-radius: 50%; display: flex; align-items: center; justify-content: center;
|
|
font-size: 0.875rem; color: #fff;
|
|
}
|
|
.timeline-content { background: #f8f9fa; border-radius: 0.375rem; padding: 0.75rem 1rem; }
|
|
</style>
|