Add delivery_note field to products for planned delivery info
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -165,6 +165,12 @@
|
||||
</label>
|
||||
</div>
|
||||
|
||||
<div>
|
||||
<label class="block text-sm font-medium mb-1">Lieferhinweis <span class="text-gray-400 font-normal">(optional, z.B. "Geplante Lieferung: Mai 2026")</span></label>
|
||||
<input type="text" name="delivery_note" value="{{ old('delivery_note', $product->delivery_note ?? '') }}"
|
||||
class="w-full border rounded px-3 py-2 text-sm" placeholder="z.B. Geplante Lieferung: Mai 2026">
|
||||
</div>
|
||||
|
||||
<div class="flex gap-2">
|
||||
<button type="submit" class="flex-1 bg-blue-600 text-white py-2 rounded hover:bg-blue-700 text-sm">Speichern</button>
|
||||
<a href="{{ route('admin.products.index') }}" class="flex-1 text-center py-2 rounded border text-sm hover:bg-gray-50">Abbrechen</a>
|
||||
|
||||
@@ -24,7 +24,13 @@
|
||||
<span class="text-xs text-gray-400">inkl. {{ number_format($product->tax_rate, 0) }}% MwSt.</span>
|
||||
</div>
|
||||
@if($product->track_stock && $product->variants->sum('stock') <= 0)
|
||||
<p class="text-xs text-red-500 mt-1">Nicht vorrätig</p>
|
||||
@if($product->delivery_note)
|
||||
<p class="text-xs text-orange-500 mt-1">📦 {{ $product->delivery_note }}</p>
|
||||
@else
|
||||
<p class="text-xs text-red-500 mt-1">Nicht vorrätig</p>
|
||||
@endif
|
||||
@elseif($product->delivery_note && !($product->track_stock && $product->variants->sum('stock') > 0))
|
||||
<p class="text-xs text-orange-500 mt-1">📦 {{ $product->delivery_note }}</p>
|
||||
@endif
|
||||
</div>
|
||||
</a>
|
||||
|
||||
@@ -74,6 +74,10 @@
|
||||
@endif
|
||||
@endif
|
||||
|
||||
@if($product->delivery_note)
|
||||
<p class="text-sm text-orange-500 mb-3">📦 {{ $product->delivery_note }}</p>
|
||||
@endif
|
||||
|
||||
{{-- In den Warenkorb --}}
|
||||
<form method="POST" action="{{ route('cart.add') }}">
|
||||
@csrf
|
||||
|
||||
Reference in New Issue
Block a user