update 20.10.2025

This commit is contained in:
Kevin Adametz 2025-10-20 17:42:08 +02:00
parent 8c11130b5d
commit a939cd51ef
616 changed files with 84821 additions and 4121 deletions

View file

@ -0,0 +1,207 @@
<form id="modal-create-shipment-form" method="POST" action="{{ route('admin.dhl.store') }}">
@csrf
<input type="hidden" name="order_id" value="{{ $order->id }}">
<div class="modal-body">
<div class="row">
{{-- Left Column: Order Info --}}
<div class="col-md-6">
<h6 class="text-primary mb-3">
<i class="fas fa-info-circle"></i>
Bestellinformationen
</h6>
<div class="card bg-light">
<div class="card-body">
<h6 class="card-title">Bestellung #{{ $order->id }}</h6>
<div class="row">
<div class="col-6">
<small class="text-muted d-block">Kunde:</small>
<strong>{{ $order->shopping_user->billing_firstname ?? '' }}
{{ $order->shopping_user->billing_lastname ?? '' }}</strong>
</div>
<div class="col-6">
<small class="text-muted d-block">Datum:</small>
<strong>{{ $order->created_at->format('d.m.Y') }}</strong>
</div>
<div class="col-6 mt-2">
<small class="text-muted d-block">Wert:</small>
<strong>{{ number_format($order->total, 2, ',', '.') }} </strong>
</div>
<div class="col-6 mt-2">
<small class="text-muted d-block">Artikel:</small>
<strong>{{ $order->shopping_order_items->count() }} Stück</strong>
</div>
</div>
</div>
</div>
</div>
{{-- Right Column: Shipment Config --}}
<div class="col-md-6">
<h6 class="text-primary mb-3">
<i class="fas fa-cog"></i>
Sendungskonfiguration
</h6>
<div class="form-group">
<label for="modal-weight" class="font-weight-semibold">
<i class="fas fa-weight"></i>
Gewicht (kg) <span class="text-danger">*</span>
</label>
<input type="number" class="form-control" id="modal-weight" name="weight" min="0.1"
max="31.5" step="0.1" value="{{ number_format($orderWeight, 1) }}" required>
<small class="form-text text-muted">
Berechnet: {{ number_format($orderWeight, 1) }} kg
</small>
</div>
<div class="form-group">
<label for="modal-product-code" class="font-weight-semibold">
<i class="fas fa-cube"></i>
Produktcode
</label>
<select class="form-control custom-select" id="modal-product-code" name="product_code">
@foreach ($productCodes as $code => $name)
<option value="{{ $code }}">{{ $code }} - {{ $name }}</option>
@endforeach
</select>
</div>
<div class="form-group">
<label for="modal-priority" class="font-weight-semibold">
<i class="fas fa-exclamation-triangle"></i>
Priorität
</label>
<select class="form-control custom-select" id="modal-priority" name="priority">
<option value="normal">Normal</option>
<option value="high">Hoch</option>
</select>
</div>
<div class="custom-control custom-checkbox">
<input type="checkbox" class="custom-control-input" id="modal-auto-track" name="auto_track"
value="1" checked>
<label class="custom-control-label" for="modal-auto-track">
Automatisches Tracking
</label>
</div>
</div>
</div>
<hr>
{{-- Shipping Address Section --}}
<div class="row">
<div class="col-12">
<h6 class="text-primary mb-3">
<i class="fas fa-map-marker-alt"></i>
Lieferadresse
@if (!empty($warnings))
<small class="text-warning">(Bitte Adresse prüfen)</small>
@else
<small class="text-muted">(zur Not anpassbar)</small>
@endif
</h6>
<div class="row">
<div class="col-md-6">
<div class="form-group">
<label for="shipping_firstname">Vorname <span class="text-danger">*</span></label>
<input type="text"
class="form-control {{ empty($shippingAddress['firstname']) ? 'is-invalid' : '' }}"
name="shipping_firstname" id="shipping_firstname"
value="{{ $shippingAddress['firstname'] ?? '' }}" required>
</div>
</div>
<div class="col-md-6">
<div class="form-group">
<label for="shipping_lastname">Nachname <span class="text-danger">*</span></label>
<input type="text"
class="form-control {{ empty($shippingAddress['lastname']) ? 'is-invalid' : '' }}"
name="shipping_lastname" id="shipping_lastname"
value="{{ $shippingAddress['lastname'] ?? '' }}" required>
</div>
</div>
<div class="col-md-12">
<div class="form-group">
<label for="shipping_company">Firma <small class="text-muted">(optional)</small></label>
<input type="text" class="form-control" name="shipping_company" id="shipping_company"
value="{{ $shippingAddress['company'] ?? '' }}">
</div>
</div>
<div class="col-md-8">
<div class="form-group">
<label for="shipping_address">Straße <span class="text-danger">*</span></label>
<input type="text"
class="form-control {{ empty($shippingAddress['address']) ? 'is-invalid' : '' }}"
name="shipping_address" id="shipping_address"
value="{{ $shippingAddress['address'] ?? '' }}" required>
</div>
</div>
<div class="col-md-4">
<div class="form-group">
<label for="shipping_houseNumber">Nr./Zusatz <span class="text-danger">*</span></label>
<input type="text"
class="form-control {{ empty($shippingAddress['houseNumber']) ? 'border-warning' : '' }}"
name="shipping_houseNumber" id="shipping_houseNumber"
value="{{ $shippingAddress['houseNumber'] ?? '' }}" required>
@if (empty($shippingAddress['houseNumber']))
<small class="text-warning">Hausnummer benötigt</small>
@endif
</div>
</div>
<div class="col-md-4">
<div class="form-group">
<label for="shipping_zipcode">PLZ <span class="text-danger">*</span></label>
<input type="text"
class="form-control {{ empty($shippingAddress['zipcode']) ? 'is-invalid' : '' }}"
name="shipping_zipcode" id="shipping_zipcode"
value="{{ $shippingAddress['zipcode'] ?? '' }}" required>
</div>
</div>
<div class="col-md-8">
<div class="form-group">
<label for="shipping_city">Ort <span class="text-danger">*</span></label>
<input type="text"
class="form-control {{ empty($shippingAddress['city']) ? 'is-invalid' : '' }}"
name="shipping_city" id="shipping_city" value="{{ $shippingAddress['city'] ?? '' }}"
required>
</div>
</div>
<div class="col-md-6">
<div class="form-group">
<label for="shipping_country">Land <span class="text-danger">*</span></label>
<select class="form-control custom-select" name="shipping_country_id"
id="shipping_country" required>
@foreach ($availableCountries as $countryOption)
<option value="{{ $countryOption->id }}"
{{ $shippingAddress['country'] && $shippingAddress['country']->id == $countryOption->id ? 'selected' : '' }}>
{{ $countryOption->getLocated() }}
</option>
@endforeach
</select>
</div>
</div>
<div class="col-md-6">
<div class="form-group">
<label for="shipping_phone">Telefon <small class="text-muted">(empfohlen)</small></label>
<input type="text" class="form-control" name="shipping_phone" id="shipping_phone"
value="{{ $shippingAddress['phone'] ?? '' }}">
</div>
</div>
</div>
</div>
</div>
</div>
<div class="modal-footer">
<button type="button" class="btn btn-secondary" data-dismiss="modal">
<i class="fas fa-times"></i> Abbrechen
</button>
<button type="submit" class="btn btn-primary" id="create-shipment-btn"
{{ !empty($errors) ? 'disabled' : '' }}>
<i class="fas fa-shipping-fast"></i> Sendung erstellen
</button>
</div>
</form>