340 lines
17 KiB
PHP
340 lines
17 KiB
PHP
@extends('admin.layouts.netgescon')
|
|
|
|
@section('title', 'Dettaglio Operazione GESCON')
|
|
|
|
@section('content')
|
|
<!-- Breadcrumb -->
|
|
<nav class="flex mb-6" aria-label="Breadcrumb">
|
|
<ol class="inline-flex items-center space-x-1 md:space-x-3">
|
|
@foreach($breadcrumbs as $breadcrumb)
|
|
<li class="inline-flex items-center">
|
|
@if(!$loop->last)
|
|
@if(isset($breadcrumb['url']))
|
|
<a href="{{ $breadcrumb['url'] }}"
|
|
class="inline-flex items-center text-sm font-medium text-gray-700 hover:text-blue-600 dark:text-gray-400 dark:hover:text-white">
|
|
<i class="{{ $breadcrumb['icon'] }} w-3 h-3 mr-2.5"></i>
|
|
{{ $breadcrumb['title'] }}
|
|
</a>
|
|
<svg class="w-3 h-3 text-gray-400 mx-1" aria-hidden="true" xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 6 10">
|
|
<path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="m1 9 4-4-4-4"/>
|
|
</svg>
|
|
@else
|
|
<span class="inline-flex items-center text-sm font-medium text-gray-700 dark:text-gray-400">
|
|
<i class="{{ $breadcrumb['icon'] }} w-3 h-3 mr-2.5"></i>
|
|
{{ $breadcrumb['title'] }}
|
|
</span>
|
|
<svg class="w-3 h-3 text-gray-400 mx-1" aria-hidden="true" xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 6 10">
|
|
<path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="m1 9 4-4-4-4"/>
|
|
</svg>
|
|
@endif
|
|
@else
|
|
<span class="ml-1 text-sm font-medium text-gray-500 md:ml-2 dark:text-gray-400">
|
|
<i class="{{ $breadcrumb['icon'] }} w-3 h-3 mr-2.5"></i>
|
|
{{ $breadcrumb['title'] }}
|
|
</span>
|
|
@endif
|
|
</li>
|
|
@endforeach
|
|
</ol>
|
|
</nav>
|
|
|
|
<!-- Page Header -->
|
|
<div class="bg-white dark:bg-gray-800 rounded-lg shadow-sm border border-gray-200 dark:border-gray-700 mb-6">
|
|
<div class="p-6">
|
|
<div class="flex flex-col lg:flex-row lg:items-center lg:justify-between">
|
|
<!-- Title & Subtitle -->
|
|
<div class="mb-4 lg:mb-0">
|
|
<h1 class="text-2xl font-bold text-gray-900 dark:text-white mb-2">
|
|
{{ $pageTitle }}
|
|
</h1>
|
|
<p class="text-gray-600 dark:text-gray-400">
|
|
{{ $pageSubtitle }}
|
|
</p>
|
|
</div>
|
|
|
|
<!-- Page Actions -->
|
|
<div class="flex flex-col sm:flex-row space-y-2 sm:space-y-0 sm:space-x-3">
|
|
<a href="{{ route('admin.contabilita-gescon.index') }}"
|
|
class="inline-flex items-center px-4 py-2 border border-gray-300 text-sm font-medium rounded-md text-gray-700 bg-white hover:bg-gray-50 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-blue-500">
|
|
<i class="fas fa-arrow-left w-4 h-4 mr-2"></i>
|
|
Torna all'Elenco
|
|
</a>
|
|
<button type="button"
|
|
class="inline-flex items-center px-4 py-2 border border-transparent text-sm font-medium rounded-md text-white bg-blue-600 hover:bg-blue-700 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-blue-500">
|
|
<i class="fas fa-edit w-4 h-4 mr-2"></i>
|
|
Modifica
|
|
</button>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
<!-- Dettaglio Operazione -->
|
|
<div class="grid grid-cols-1 lg:grid-cols-3 gap-6">
|
|
<!-- Informazioni Principali -->
|
|
<div class="lg:col-span-2">
|
|
<div class="bg-white dark:bg-gray-800 rounded-lg shadow-sm border border-gray-200 dark:border-gray-700">
|
|
<div class="p-6">
|
|
<h3 class="text-lg font-semibold text-gray-900 dark:text-white mb-4">
|
|
<i class="fas fa-info-circle w-5 h-5 mr-2 text-blue-500"></i>
|
|
Informazioni Principali
|
|
</h3>
|
|
|
|
<div class="grid grid-cols-1 md:grid-cols-2 gap-6">
|
|
<!-- Dettagli Operazione -->
|
|
<div class="space-y-4">
|
|
<div>
|
|
<label class="block text-sm font-medium text-gray-700 dark:text-gray-300 mb-1">
|
|
ID Operazione GESCON
|
|
</label>
|
|
<p class="text-sm text-gray-900 dark:text-gray-100 bg-gray-50 dark:bg-gray-700 p-2 rounded">
|
|
{{ $operazione->id_operazione_gescon ?? '-' }}
|
|
</p>
|
|
</div>
|
|
|
|
<div>
|
|
<label class="block text-sm font-medium text-gray-700 dark:text-gray-300 mb-1">
|
|
Data Spesa
|
|
</label>
|
|
<p class="text-sm text-gray-900 dark:text-gray-100 bg-gray-50 dark:bg-gray-700 p-2 rounded">
|
|
{{ $operazione->data_spesa ? \Carbon\Carbon::parse($operazione->data_spesa)->format('d/m/Y') : '-' }}
|
|
</p>
|
|
</div>
|
|
|
|
<div>
|
|
<label class="block text-sm font-medium text-gray-700 dark:text-gray-300 mb-1">
|
|
Codice Spesa
|
|
</label>
|
|
<p class="text-sm text-gray-900 dark:text-gray-100 bg-gray-50 dark:bg-gray-700 p-2 rounded">
|
|
{{ $operazione->cod_spe ?? '-' }}
|
|
</p>
|
|
</div>
|
|
|
|
<div>
|
|
<label class="block text-sm font-medium text-gray-700 dark:text-gray-300 mb-1">
|
|
Natura
|
|
</label>
|
|
<p class="text-sm">
|
|
<span class="inline-flex px-2 py-1 text-xs font-semibold rounded-full
|
|
{{ $operazione->natura === 'A' ? 'bg-blue-100 text-blue-800' :
|
|
($operazione->natura === 'P' ? 'bg-green-100 text-green-800' : 'bg-gray-100 text-gray-800') }}">
|
|
{{ $operazione->natura ?? '-' }}
|
|
</span>
|
|
</p>
|
|
</div>
|
|
|
|
<div>
|
|
<label class="block text-sm font-medium text-gray-700 dark:text-gray-300 mb-1">
|
|
Anno Gestione
|
|
</label>
|
|
<p class="text-sm text-gray-900 dark:text-gray-100 bg-gray-50 dark:bg-gray-700 p-2 rounded">
|
|
{{ $operazione->anno_gestione ?? '-' }}
|
|
</p>
|
|
</div>
|
|
</div>
|
|
|
|
<!-- Importi -->
|
|
<div class="space-y-4">
|
|
<div>
|
|
<label class="block text-sm font-medium text-gray-700 dark:text-gray-300 mb-1">
|
|
Importo Euro
|
|
</label>
|
|
<div class="text-2xl font-bold p-3 rounded
|
|
{{ $operazione->importo_euro > 0 ? 'text-green-600 bg-green-50' :
|
|
($operazione->importo_euro < 0 ? 'text-red-600 bg-red-50' : 'text-gray-600 bg-gray-50') }}">
|
|
@if($operazione->importo_euro > 0)
|
|
+€{{ number_format($operazione->importo_euro, 2) }}
|
|
@elseif($operazione->importo_euro < 0)
|
|
-€{{ number_format(abs($operazione->importo_euro), 2) }}
|
|
@else
|
|
€0,00
|
|
@endif
|
|
</div>
|
|
</div>
|
|
|
|
@if($operazione->importo_lire)
|
|
<div>
|
|
<label class="block text-sm font-medium text-gray-700 dark:text-gray-300 mb-1">
|
|
Importo Lire (Storico)
|
|
</label>
|
|
<p class="text-sm text-gray-500 dark:text-gray-400 bg-gray-50 dark:bg-gray-700 p-2 rounded">
|
|
{{ number_format($operazione->importo_lire, 0) }} ₤
|
|
</p>
|
|
</div>
|
|
@endif
|
|
|
|
<div>
|
|
<label class="block text-sm font-medium text-gray-700 dark:text-gray-300 mb-1">
|
|
Codice Fornitore
|
|
</label>
|
|
<p class="text-sm text-gray-900 dark:text-gray-100 bg-gray-50 dark:bg-gray-700 p-2 rounded">
|
|
{{ $operazione->cod_for ?? '-' }}
|
|
</p>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
<!-- Descrizioni -->
|
|
<div class="mt-6 space-y-4">
|
|
<div>
|
|
<label class="block text-sm font-medium text-gray-700 dark:text-gray-300 mb-1">
|
|
Descrizione Spesa
|
|
</label>
|
|
<p class="text-sm text-gray-900 dark:text-gray-100 bg-gray-50 dark:bg-gray-700 p-3 rounded">
|
|
{{ $operazione->descrizione_spesa ?? '-' }}
|
|
</p>
|
|
</div>
|
|
|
|
@if($operazione->ragione_sociale_fornitore)
|
|
<div>
|
|
<label class="block text-sm font-medium text-gray-700 dark:text-gray-300 mb-1">
|
|
Ragione Sociale Fornitore
|
|
</label>
|
|
<p class="text-sm text-gray-900 dark:text-gray-100 bg-gray-50 dark:bg-gray-700 p-3 rounded">
|
|
{{ $operazione->ragione_sociale_fornitore }}
|
|
</p>
|
|
</div>
|
|
@endif
|
|
|
|
@if($operazione->beneficiario)
|
|
<div>
|
|
<label class="block text-sm font-medium text-gray-700 dark:text-gray-300 mb-1">
|
|
Beneficiario
|
|
</label>
|
|
<p class="text-sm text-gray-900 dark:text-gray-100 bg-gray-50 dark:bg-gray-700 p-3 rounded">
|
|
{{ $operazione->beneficiario }}
|
|
</p>
|
|
</div>
|
|
@endif
|
|
|
|
@if($operazione->note)
|
|
<div>
|
|
<label class="block text-sm font-medium text-gray-700 dark:text-gray-300 mb-1">
|
|
Note
|
|
</label>
|
|
<p class="text-sm text-gray-900 dark:text-gray-100 bg-gray-50 dark:bg-gray-700 p-3 rounded">
|
|
{{ $operazione->note }}
|
|
</p>
|
|
</div>
|
|
@endif
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
<!-- Informazioni Aggiuntive -->
|
|
<div class="space-y-6">
|
|
<!-- Dati Fattura -->
|
|
<div class="bg-white dark:bg-gray-800 rounded-lg shadow-sm border border-gray-200 dark:border-gray-700">
|
|
<div class="p-6">
|
|
<h3 class="text-lg font-semibold text-gray-900 dark:text-white mb-4">
|
|
<i class="fas fa-file-invoice w-5 h-5 mr-2 text-green-500"></i>
|
|
Dati Fattura
|
|
</h3>
|
|
|
|
<div class="space-y-3">
|
|
<div>
|
|
<label class="block text-xs font-medium text-gray-700 dark:text-gray-300 mb-1">
|
|
Numero Fattura
|
|
</label>
|
|
<p class="text-sm text-gray-900 dark:text-gray-100">
|
|
{{ $operazione->numero_fattura ?? '-' }}
|
|
</p>
|
|
</div>
|
|
|
|
<div>
|
|
<label class="block text-xs font-medium text-gray-700 dark:text-gray-300 mb-1">
|
|
Data Fattura
|
|
</label>
|
|
<p class="text-sm text-gray-900 dark:text-gray-100">
|
|
{{ $operazione->data_fattura ? \Carbon\Carbon::parse($operazione->data_fattura)->format('d/m/Y') : '-' }}
|
|
</p>
|
|
</div>
|
|
|
|
<div>
|
|
<label class="block text-xs font-medium text-gray-700 dark:text-gray-300 mb-1">
|
|
Data Scadenza
|
|
</label>
|
|
<p class="text-sm text-gray-900 dark:text-gray-100">
|
|
{{ $operazione->data_scadenza ? \Carbon\Carbon::parse($operazione->data_scadenza)->format('d/m/Y') : '-' }}
|
|
</p>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
<!-- Dati Tecnici -->
|
|
<div class="bg-white dark:bg-gray-800 rounded-lg shadow-sm border border-gray-200 dark:border-gray-700">
|
|
<div class="p-6">
|
|
<h3 class="text-lg font-semibold text-gray-900 dark:text-white mb-4">
|
|
<i class="fas fa-cogs w-5 h-5 mr-2 text-gray-500"></i>
|
|
Dati Tecnici
|
|
</h3>
|
|
|
|
<div class="space-y-3">
|
|
<div>
|
|
<label class="block text-xs font-medium text-gray-700 dark:text-gray-300 mb-1">
|
|
ID Interno
|
|
</label>
|
|
<p class="text-sm text-gray-900 dark:text-gray-100 font-mono">
|
|
{{ $operazione->id }}
|
|
</p>
|
|
</div>
|
|
|
|
<div>
|
|
<label class="block text-xs font-medium text-gray-700 dark:text-gray-300 mb-1">
|
|
Data Importazione
|
|
</label>
|
|
<p class="text-sm text-gray-900 dark:text-gray-100">
|
|
{{ $operazione->created_at ? \Carbon\Carbon::parse($operazione->created_at)->format('d/m/Y H:i') : '-' }}
|
|
</p>
|
|
</div>
|
|
|
|
@if($operazione->updated_at && $operazione->updated_at !== $operazione->created_at)
|
|
<div>
|
|
<label class="block text-xs font-medium text-gray-700 dark:text-gray-300 mb-1">
|
|
Ultima Modifica
|
|
</label>
|
|
<p class="text-sm text-gray-900 dark:text-gray-100">
|
|
{{ $operazione->updated_at ? \Carbon\Carbon::parse($operazione->updated_at)->format('d/m/Y H:i') : '-' }}
|
|
</p>
|
|
</div>
|
|
@endif
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
<!-- Azioni Rapide -->
|
|
<div class="bg-white dark:bg-gray-800 rounded-lg shadow-sm border border-gray-200 dark:border-gray-700">
|
|
<div class="p-6">
|
|
<h3 class="text-lg font-semibold text-gray-900 dark:text-white mb-4">
|
|
<i class="fas fa-bolt w-5 h-5 mr-2 text-yellow-500"></i>
|
|
Azioni Rapide
|
|
</h3>
|
|
|
|
<div class="space-y-2">
|
|
<button type="button"
|
|
class="w-full text-left px-3 py-2 text-sm text-gray-700 dark:text-gray-300 hover:bg-gray-50 dark:hover:bg-gray-700 rounded-md border border-gray-200 dark:border-gray-600">
|
|
<i class="fas fa-copy w-4 h-4 mr-2 text-blue-500"></i>
|
|
Duplica Operazione
|
|
</button>
|
|
|
|
<button type="button"
|
|
class="w-full text-left px-3 py-2 text-sm text-gray-700 dark:text-gray-300 hover:bg-gray-50 dark:hover:bg-gray-700 rounded-md border border-gray-200 dark:border-gray-600">
|
|
<i class="fas fa-download w-4 h-4 mr-2 text-green-500"></i>
|
|
Esporta PDF
|
|
</button>
|
|
|
|
<button type="button"
|
|
class="w-full text-left px-3 py-2 text-sm text-red-600 dark:text-red-400 hover:bg-red-50 dark:hover:bg-red-900 rounded-md border border-red-200 dark:border-red-600">
|
|
<i class="fas fa-trash w-4 h-4 mr-2"></i>
|
|
Elimina Operazione
|
|
</button>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
@endsection
|