@extends('layouts.layout-2') @section('content')

DHL Sendung #{{ $shipment->id }} @if($shipment->type == 'return') RETOURE @endif

Zurück zum Cockpit @if($shipment->shoppingOrder) Bestellung anzeigen @endif
Status
@switch($shipment->status) @case('pending')
{{ __('dhl.status.pending') }}
@break @case('created')
{{ __('dhl.status.created') }}
@break @case('shipped')
{{ __('dhl.status.shipped') }}
@break @case('delivered')
{{ __('dhl.status.delivered') }}
@break @case('canceled') @case('cancelled')
{{ __('dhl.status.canceled') }}
@break @case('failed')
{{ __('dhl.status.failed') }}
@break @default
{{ $shipment->getStatusTranslation() }}
@endswitch
Sendungsnummer
@if($shipment->dhl_shipment_no) {{ $shipment->dhl_shipment_no }} @else Nicht verfügbar @endif
Tracking
@if(false) @php $publicTrackingUrl = \App\Domain\EarlyDomainParser::getMainUrl().'/tracking'; @endphp {{ $shipment->dhl_shipment_no }}
Verfolgen @else Nicht verfügbar @endif
Gewicht
{{ number_format($shipment->weight_kg, 2, ',', '.') }} kg
@if(!in_array($shipment->status, ['canceled', 'cancelled']))
@if($shipment->label_path) Label herunterladen @endif @if($shipment->type == 'outbound' && !$shipment->returns->count()) @endif @if($shipment->dhl_shipment_no) @if($shipment->canSendTrackingEmail()) @endif @endif
@endif
Sendungsinformationen
{{-- --}}
ID: #{{ $shipment->id }}
DHL Sendungsnummer: @if($shipment->dhl_shipment_no) {{ $shipment->dhl_shipment_no }} @else Nicht verfügbar @endif
Referenz: @if($shipment->reference) {{ $shipment->reference }} @else Nicht gesetzt @endif
Routing-Code: @if($shipment->routing_code) {{ $shipment->routing_code }} @else Nicht verfügbar @endif
Rechnungsnummer: @if($shipment->billing_number) {{ $shipment->billing_number }} @else Nicht verfügbar @endif
Typ: @if($shipment->type == 'outbound') {{ __('dhl.type.outbound') }} @else {{ __('dhl.type.return') }} @if($shipment->relatedShipment)
Bezieht sich auf Sendung #{{ $shipment->relatedShipment->id }} @endif @endif
{{ __('dhl.fields.product_code') }}: {{ $shipment->product_code }} - {{ $shipment->getProductCodeTranslation() }}
Label-Format: {{ strtoupper($shipment->label_format) }}
@if($shipment->last_tracked_at) @endif @if($shipment->length || $shipment->width || $shipment->height) @endif
Erstellt: {{ $shipment->created_at->format('d.m.Y H:i:s') }}
Letzte Änderung: {{ $shipment->updated_at->format('d.m.Y H:i:s') }}
Letztes Tracking: {{ $shipment->last_tracked_at->format('d.m.Y H:i:s') }}
Abmessungen: {{ $shipment->length }}×{{ $shipment->width }}×{{ $shipment->height }} cm
@if($shipment->firstname || $shipment->lastname || $shipment->company || $shipment->recipient)
Empfängerinformationen
@if($shipment->company) @endif @if($shipment->recipient && isset($shipment->recipient['postnumber'])) @endif
Name: @if($shipment->firstname || $shipment->lastname) {{ $shipment->firstname }} {{ $shipment->lastname }} @elseif($shipment->recipient && isset($shipment->recipient['firstname'])) {{ $shipment->recipient['firstname'] }} {{ $shipment->recipient['lastname'] }} @else Nicht verfügbar @endif
Firma: @if($shipment->company) {{ $shipment->company }} @elseif($shipment->recipient && isset($shipment->recipient['company'])) {{ $shipment->recipient['company'] }} @else - @endif
Postnummer: {{ $shipment->recipient['postnumber'] }}
Straße: @if($shipment->recipient && isset($shipment->recipient['street'])) {{ $shipment->recipient['street'] }} @if(isset($shipment->recipient['houseNumber'])) {{ $shipment->recipient['houseNumber'] }} @endif @else Nicht verfügbar @endif
PLZ: @if($shipment->recipient && isset($shipment->recipient['postalCode'])) {{ $shipment->recipient['postalCode'] }} @else Nicht verfügbar @endif
Stadt: @if($shipment->recipient && isset($shipment->recipient['city'])) {{ $shipment->recipient['city'] }} @else Nicht verfügbar @endif
Land: @if($shipment->recipient && isset($shipment->recipient['country'])) {{ $shipment->recipient['country'] }} @else Nicht verfügbar @endif
E-Mail: @if($shipment->recipient && isset($shipment->recipient['email'])) {{ $shipment->recipient['email'] }} @else Nicht verfügbar @endif
Telefon: @if($shipment->recipient && isset($shipment->recipient['phone'])) {{ $shipment->recipient['phone'] }} @else Nicht verfügbar @endif
@endif @if($shipment->shoppingOrder)
Bestellinformationen
Bestellungs-ID: #{{ $shipment->shoppingOrder->id }}
Kunde: @if($shipment->shoppingOrder->shopping_user) {{ $shipment->shoppingOrder->shopping_user->billing_firstname }} {{ $shipment->shoppingOrder->shopping_user->billing_lastname }}
{{ $shipment->shoppingOrder->shopping_user->billing_email }} @else Unbekannt @endif
Bestelldatum: {{ $shipment->shoppingOrder->created_at->format('d.m.Y H:i') }}
Bestellwert: {{ number_format($shipment->shoppingOrder->total, 2, ',', '.') }} €
Status: {{ $shipment->shoppingOrder->getShippedType() }}
Artikel: {{ $shipment->shoppingOrder->shopping_order_items->count() ?? 0 }} Artikel
@endif
@if($shipment->dhl_shipment_no)
Tracking-E-Mail Status
@if($shipment->wasTrackingEmailSent())
Zuletzt gesendet
Am {{ $shipment->tracking_email_sent_at->format('d.m.Y \u\m H:i') }} Uhr ({{ $shipment->tracking_email_type === 'auto' ? 'automatisch' : 'manuell' }})
@php($trackingEmailHistory = $shipment->getTrackingEmailHistory()) @if(!empty($trackingEmailHistory))
@foreach($trackingEmailHistory as $entry) @endforeach
Zeitpunkt Typ Status Empfänger Sendungen
@if(!empty($entry['sent_at'])) {{ \Carbon\Carbon::parse($entry['sent_at'])->format('d.m.Y H:i') }} @else - @endif {{ ($entry['type'] ?? '') === 'auto' ? 'Automatisch' : 'Manuell' }} {{ \Acme\Dhl\Models\DhlShipment::getStatusTranslationFor($entry['status'] ?? 'unknown') }} @if(!empty($entry['tracking_status']))
{{ $entry['tracking_status'] }} @endif
@if(!empty($entry['recipient_email'])) {{ $entry['recipient_email'] }} @else - @endif @if(!empty($entry['included_shipment_ids'])) #{{ implode(', #', $entry['included_shipment_ids']) }} @else - @endif
@endif @else
Noch nicht gesendet
@if($shipment->canSendTrackingEmail()) Klicken Sie auf "Tracking-E-Mail senden" um den Kunden zu benachrichtigen. @else E-Mail kann nicht gesendet werden (keine Empfänger-E-Mail verfügbar). @endif
@endif
@endif @if($shipment->tracking_status || $shipment->dhl_shipment_no)
Tracking-Informationen
@if($shipment->dhl_shipment_no) Bei DHL verfolgen @endif
@if($shipment->tracking_status)
Aktueller Status: {{ $shipment->tracking_status }}
@if($shipment->last_tracked_at) Zuletzt aktualisiert: {{ $shipment->last_tracked_at->format('d.m.Y H:i') }} @endif
@endif {{-- Tracking Events Timeline --}} @if($shipment->trackingEvents && $shipment->trackingEvents->count() > 0)
@foreach($shipment->trackingEvents as $index => $event)
@if($index === 0) @if($event->status_code === 'delivered') @elseif($event->status_code === 'transit') @elseif($event->status_code === 'out-for-delivery') @elseif($event->status_code === 'failure' || $event->status_code === 'exception') @elseif($event->status_code === 'returned') @else @endif @else @endif
{{ $event->status_text }}
{{ $event->event_time->format('d.m.Y H:i') }} Uhr @if($event->location) · {{ $event->location }} @endif
@if(!$loop->last)
@endif @endforeach
@elseif(!$shipment->tracking_status)
Noch keine Tracking-Daten vorhanden. Klicken Sie auf "Tracking aktualisieren" um die Daten abzurufen.
@endif
@endif @if($shipment->type == 'outbound' && $shipment->relatedShipments && $shipment->relatedShipments->count() > 0)
Verknüpfte Retouren
@foreach($shipment->relatedShipments as $relatedShipment)
Retoure #{{ $relatedShipment->id }}
{{ $relatedShipment->created_at->format('d.m.Y H:i') }}
{{ $relatedShipment->status }}
@endforeach
@endif @if($shipment->services)
Zusatzleistungen
@foreach($shipment->services as $service => $enabled) @if($enabled)
{{ $service }}
@endif @endforeach
@endif @if($shipment->api_response_data && auth()->user()->isSuperAdmin())
API Response (Debug)
{{ json_encode($shipment->api_response_data, JSON_PRETTY_PRINT) }}
@endif
@endsection @section('scripts') @endsection