gruene-seele/resources/views/admin/inventory/general/index.blade.php
Kevin Adametz d05df498d3 Warenwirtschaft: AP-21 INCI-Erweiterungen
- Lagerort-Stammdaten Raum/Regal/Fach (storage_rooms/shelves/slots) mit CRUD
  auf Einstellungen -> Allgemein (SettingCrudController-Kinder, ein gemeinsamer
  StoreStorageSegmentRequest, generische Partials setting-list-card/-segment-form)
- Ingredient: alt_name (Handelsname), Lagerort-FKs + storageLabel(),
  scopeUsedInActiveRecipes()
- INCI-Formular: Lieferanten-Repeater mit Shop-URL je Lieferant (leer = Mail),
  Alternativname, drei Lagerort-Dropdowns
- INCI-Liste: Filter "nur aktive (in Rezeptur aktiver Produkte)" + Spalte
  Alternativer Name
- Rohstoffbestand-Detail: Bestellweg pro INCI-Lieferant (Pivot-URL statt
  order_method-Fallback), Kopf zeigt Alternativname + Lagerort
- Hinweise-Doku fortgeschrieben inkl. Chargen-Format-Entscheid ttmmjj (AP-24)

Tests: StorageSettingsTest, IngredientActiveRecipeFilterTest,
IngredientOrderFieldsTest (Repeater-Format), RawMaterialStockTest erweitert
(volle Suite 170 gruen, 613 Assertions)

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
2026-07-06 11:36:28 +00:00

197 lines
9.9 KiB
PHP
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

@extends('layouts.layout-2')
@section('content')
@include('admin.inventory.partials.wawi-ui')
<div class="wawi-page">
<div class="wawi-page-head">
<div>
<h1 class="wawi-page-head__title">{{ __('Einstellungen') }}</h1>
<p class="wawi-page-head__subtitle">{{ __('Umsatzsteuersätze, Lieferzeit-Vorlagen, Ausschuss-Gründe und Lagerorte') }}</p>
</div>
</div>
<div class="wawi-card">
<div class="wawi-card__header">
<span>{{ __('Umsatzsteuersätze') }}</span>
<a href="{{ route('admin.inventory.tax-rates.create') }}" class="btn btn-sm btn-primary">{{ __('Neu anlegen') }}</a>
</div>
<div class="table-responsive">
<table class="table wawi-table">
<thead>
<tr>
<th style="max-width: 60px;">&nbsp;</th>
<th>{{ __('Name') }}</th>
<th>{{ __('Satz') }}</th>
<th>{{ __('Status') }}</th>
<th></th>
</tr>
</thead>
<tbody>
@forelse($taxRates as $taxRate)
<tr>
<td>
<a href="{{ route('admin.inventory.tax-rates.edit', $taxRate) }}"
class="btn icon-btn btn-sm btn-primary">
<span class="far fa-edit"></span>
</a>
</td>
<td>{{ $taxRate->name }}</td>
<td>{{ number_format($taxRate->percent, 2, ',', '.') }}&nbsp;%</td>
<td>
@if ($taxRate->active)
<span class="wawi-pill wawi-pill--ok">{{ __('Aktiv') }}</span>
@else
<span class="wawi-pill wawi-pill--danger">{{ __('Inaktiv') }}</span>
@endif
</td>
<td>
<form action="{{ route('admin.inventory.tax-rates.destroy', $taxRate) }}" method="post"
class="d-inline" onsubmit="return confirm('{{ __('Really delete entry?') }}');">
@csrf
@method('DELETE')
<button type="submit" class="btn btn-link text-danger p-0"
title="{{ __('Delete') }}"><i class="far fa-trash-alt"></i></button>
</form>
</td>
</tr>
@empty
<tr>
<td colspan="5"><div class="wawi-empty">{{ __('Noch keine Umsatzsteuersätze angelegt.') }}</div></td>
</tr>
@endforelse
</tbody>
</table>
</div>
</div>
<div class="wawi-card">
<div class="wawi-card__header">
<span>{{ __('Lieferzeit-Vorlagen') }}</span>
<a href="{{ route('admin.inventory.delivery-times.create') }}" class="btn btn-sm btn-primary">{{ __('Neu anlegen') }}</a>
</div>
<div class="table-responsive">
<table class="table wawi-table">
<thead>
<tr>
<th style="max-width: 60px;">&nbsp;</th>
<th>{{ __('Bezeichnung') }}</th>
<th>{{ __('Tage') }}</th>
<th>{{ __('Status') }}</th>
<th></th>
</tr>
</thead>
<tbody>
@forelse($deliveryTimes as $deliveryTime)
<tr>
<td>
<a href="{{ route('admin.inventory.delivery-times.edit', $deliveryTime) }}"
class="btn icon-btn btn-sm btn-primary">
<span class="far fa-edit"></span>
</a>
</td>
<td>{{ $deliveryTime->label }}</td>
<td>{{ $deliveryTime->days !== null ? $deliveryTime->days : '–' }}</td>
<td>
@if ($deliveryTime->active)
<span class="wawi-pill wawi-pill--ok">{{ __('Aktiv') }}</span>
@else
<span class="wawi-pill wawi-pill--danger">{{ __('Inaktiv') }}</span>
@endif
</td>
<td>
<form action="{{ route('admin.inventory.delivery-times.destroy', $deliveryTime) }}"
method="post" class="d-inline"
onsubmit="return confirm('{{ __('Really delete entry?') }}');">
@csrf
@method('DELETE')
<button type="submit" class="btn btn-link text-danger p-0"
title="{{ __('Delete') }}"><i class="far fa-trash-alt"></i></button>
</form>
</td>
</tr>
@empty
<tr>
<td colspan="5"><div class="wawi-empty">{{ __('Noch keine Lieferzeit-Vorlagen angelegt.') }}</div></td>
</tr>
@endforelse
</tbody>
</table>
</div>
</div>
<div class="wawi-card">
<div class="wawi-card__header">
<span>{{ __('Ausschuss-Gründe') }}</span>
<a href="{{ route('admin.inventory.disposal-reasons.create') }}" class="btn btn-sm btn-primary">{{ __('Neu anlegen') }}</a>
</div>
<div class="table-responsive">
<table class="table wawi-table">
<thead>
<tr>
<th style="max-width: 60px;">&nbsp;</th>
<th>{{ __('Bezeichnung') }}</th>
<th>{{ __('Status') }}</th>
<th></th>
</tr>
</thead>
<tbody>
@forelse($disposalReasons as $disposalReason)
<tr>
<td>
<a href="{{ route('admin.inventory.disposal-reasons.edit', $disposalReason) }}"
class="btn icon-btn btn-sm btn-primary">
<span class="far fa-edit"></span>
</a>
</td>
<td>{{ $disposalReason->label }}</td>
<td>
@if ($disposalReason->active)
<span class="wawi-pill wawi-pill--ok">{{ __('Aktiv') }}</span>
@else
<span class="wawi-pill wawi-pill--danger">{{ __('Inaktiv') }}</span>
@endif
</td>
<td>
<form action="{{ route('admin.inventory.disposal-reasons.destroy', $disposalReason) }}"
method="post" class="d-inline"
onsubmit="return confirm('{{ __('Really delete entry?') }}');">
@csrf
@method('DELETE')
<button type="submit" class="btn btn-link text-danger p-0"
title="{{ __('Delete') }}"><i class="far fa-trash-alt"></i></button>
</form>
</td>
</tr>
@empty
<tr>
<td colspan="4"><div class="wawi-empty">{{ __('Noch keine Ausschuss-Gründe angelegt.') }}</div></td>
</tr>
@endforelse
</tbody>
</table>
</div>
</div>
@include('admin.inventory.partials.setting-list-card', [
'title' => __('Lagerorte: Räume'),
'routePrefix' => 'admin.inventory.storage-rooms',
'values' => $storageRooms,
'emptyText' => __('Noch keine Räume angelegt.'),
])
@include('admin.inventory.partials.setting-list-card', [
'title' => __('Lagerorte: Regale'),
'routePrefix' => 'admin.inventory.storage-shelves',
'values' => $storageShelves,
'emptyText' => __('Noch keine Regale angelegt.'),
])
@include('admin.inventory.partials.setting-list-card', [
'title' => __('Lagerorte: Fächer / Buchstaben'),
'routePrefix' => 'admin.inventory.storage-slots',
'values' => $storageSlots,
'emptyText' => __('Noch keine Fächer angelegt.'),
])
</div>
@endsection