April 2026 waren Wirtschaft Feedback
This commit is contained in:
parent
02f2a4c23e
commit
9ce711d6b2
167 changed files with 25278 additions and 8518 deletions
|
|
@ -0,0 +1,85 @@
|
|||
@extends('layouts.layout-2')
|
||||
|
||||
@section('content')
|
||||
<div class="card">
|
||||
<h6 class="card-header d-flex justify-content-between align-items-center">
|
||||
<span>{{ __('Wareneingang') }}</span>
|
||||
@if(Auth::user()->isAdmin())
|
||||
<a href="{{ route('admin.inventory.stock-entries.create') }}" class="btn btn-sm btn-primary">{{ __('Neuer Einkauf') }}</a>
|
||||
@endif
|
||||
</h6>
|
||||
<div class="card-datatable table-responsive">
|
||||
<table class="datatables-style table table-striped table-bordered">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>{{ __('Status') }}</th>
|
||||
<th>{{ __('Bestellt') }}</th>
|
||||
<th>{{ __('Art') }}</th>
|
||||
<th>{{ __('Artikel') }}</th>
|
||||
<th>{{ __('Lieferant') }}</th>
|
||||
<th>{{ __('Menge') }}</th>
|
||||
<th style="max-width: 80px;"></th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
@foreach($values as $row)
|
||||
<tr>
|
||||
<td data-sort="{{ $row->status === 'pending' ? 0 : 1 }}">
|
||||
@if($row->status === 'pending')
|
||||
<span class="badge badge-warning">{{ __('Offen') }}</span>
|
||||
@else
|
||||
<span class="badge badge-success">{{ __('Eingegangen') }}</span>
|
||||
@endif
|
||||
</td>
|
||||
<td data-sort="{{ $row->ordered_at?->timestamp ?? 0 }}">{{ $row->ordered_at?->format('d.m.Y') }}</td>
|
||||
<td>{{ $entryTypeLabels[$row->entry_type] ?? $row->entry_type }}</td>
|
||||
<td>
|
||||
@if($row->entry_type === 'ingredient' && $row->ingredient)
|
||||
{{ $row->ingredient->name }}
|
||||
@elseif($row->packagingItem)
|
||||
{{ $row->packagingItem->name }}
|
||||
@else
|
||||
—
|
||||
@endif
|
||||
</td>
|
||||
<td>{{ $row->supplier?->name ?? '—' }}</td>
|
||||
<td>
|
||||
@if($row->unit === 'gram')
|
||||
{{ \App\Services\Util::formatNumber($row->ordered_quantity) }} g
|
||||
@else
|
||||
{{ \App\Services\Util::formatNumber($row->ordered_quantity, 0) }} {{ __('Stk.') }}
|
||||
@endif
|
||||
</td>
|
||||
<td>
|
||||
<a href="{{ route('admin.inventory.stock-entries.show', $row) }}" class="btn icon-btn btn-sm btn-primary" title="{{ __('Details') }}">
|
||||
<span class="far fa-eye"></span>
|
||||
</a>
|
||||
@if(Auth::user()->isAdmin() && $row->status === 'pending')
|
||||
<a href="{{ route('admin.inventory.stock-entries.edit', $row) }}" class="btn icon-btn btn-sm btn-secondary">
|
||||
<span class="far fa-edit"></span>
|
||||
</a>
|
||||
<form action="{{ route('admin.inventory.stock-entries.destroy', $row) }}" method="post" class="d-inline"
|
||||
onsubmit="return confirm(@json(__('Eintrag wirklich löschen?')));">
|
||||
@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>
|
||||
@endif
|
||||
</td>
|
||||
</tr>
|
||||
@endforeach
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
<script>
|
||||
$(document).ready(function () {
|
||||
$('.datatables-style').dataTable({
|
||||
"bLengthChange": false,
|
||||
"iDisplayLength": 100,
|
||||
"order": [[0, "asc"], [1, "desc"]],
|
||||
"language": {"url": "/js/German.json"}
|
||||
});
|
||||
});
|
||||
</script>
|
||||
@endsection
|
||||
Loading…
Add table
Add a link
Reference in a new issue