Fix: Aggiornato dashboard per usare layout universale

 Modifiche:
- Dashboard Admin: usa @extends('layouts.app-universal')
- Dashboard Super-Admin: usa @extends('layouts.app-universal')
- Rimosso selector stabile duplicato (ora nella sidebar)
- Migliorato header dashboard con icone

🎯 Obiettivo: Risolve problema posizionamento contenuto a destra della sidebar
This commit is contained in:
Pikappa2 2025-07-07 17:51:04 +02:00
parent 1b884feda5
commit 517f313af9
2 changed files with 26 additions and 31 deletions

View File

@ -1,12 +1,19 @@
<x-app-layout> @extends('layouts.app-universal')
<x-slot name="header">
<h2 class="font-semibold text-xl text-gray-800 dark:text-gray-200 leading-tight">
{{ __('Dashboard Amministratore') }}
</h2>
</x-slot>
<div class="py-12"> @section('content')
<div class="max-w-7xl mx-auto sm:px-6 lg:px-8 space-y-6"> <div class="space-y-6">
<!-- Header Dashboard -->
<div class="bg-white dark:bg-gray-800 overflow-hidden shadow-sm sm:rounded-lg">
<div class="p-6 bg-white dark:bg-gray-800 border-b border-gray-200 dark:border-gray-700">
<h2 class="text-3xl font-bold text-gray-800 dark:text-white">
<i class="fas fa-tachometer-alt text-blue-500 mr-2"></i>
Dashboard Amministratore
</h2>
<p class="text-gray-600 dark:text-gray-300 mt-2">
Benvenuto {{ auth()->user()->name }} - Gestione condomini
</p>
</div>
</div>
<!-- Statistiche Principali --> <!-- Statistiche Principali -->
<div class="grid grid-cols-1 md:grid-cols-4 gap-6"> <div class="grid grid-cols-1 md:grid-cols-4 gap-6">
@ -266,4 +273,5 @@
</div> </div>
</div> </div>
</div> </div>
</x-app-layout> </div>
@endsection

View File

@ -1,30 +1,17 @@
@extends('superadmin.layouts.app') @extends('layouts.app-universal')
@section('content') @section('content')
<div class="space-y-6"> <div class="space-y-6">
<!-- Header --> <!-- Header Dashboard -->
<div class="bg-white dark:bg-gray-800 overflow-hidden shadow-sm sm:rounded-lg"> <div class="bg-white dark:bg-gray-800 overflow-hidden shadow-sm sm:rounded-lg">
<div class="p-6 bg-white dark:bg-gray-800 border-b border-gray-200 dark:border-gray-700"> <div class="p-6 bg-white dark:bg-gray-800 border-b border-gray-200 dark:border-gray-700">
<h2 class="text-3xl font-bold text-gray-800 dark:text-white">Dashboard Super Admin</h2> <h2 class="text-3xl font-bold text-gray-800 dark:text-white">
<p class="text-gray-600 dark:text-gray-300 mt-2">Benvenuto nel pannello di amministrazione del sistema</p> <i class="fas fa-crown text-red-500 mr-2"></i>
</div> Dashboard Super Admin
</div> </h2>
<p class="text-gray-600 dark:text-gray-300 mt-2">
<!-- Riquadro stabile sopra la dashboard --> Benvenuto nel pannello di amministrazione del sistema
<div class="w-full flex flex-col items-center py-2 bg-yellow-100 dark:bg-gray-700 border-b border-yellow-300 dark:border-gray-600 sticky top-0 z-20"> </p>
<span class="text-xs text-gray-700 dark:text-gray-300 mb-1">{{ $annoAttivo ?? date("Y") }}/{{ $gestione ?? "Ord." }}{{ isset($gestione2) ? ' - '.$gestione2 : '' }}</span>
<div class="flex items-center gap-2 bg-yellow-200 dark:bg-gray-800 rounded px-2 py-1 shadow" style="min-width: 180px;">
<div class="flex flex-col justify-center items-center mr-1">
<button id="prev-stabile" class="w-6 h-6 flex items-center justify-center rounded bg-indigo-500 text-white hover:bg-indigo-700 text-xs mb-1" title="Stabile precedente">
<svg xmlns="http://www.w3.org/2000/svg" class="icon icon-tabler icon-tabler-chevron-up" width="18" height="18" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><path stroke="none" d="M0 0h24v24H0z" fill="none"/><polyline points="6 15 12 9 18 15" /></svg>
</button>
<button id="next-stabile" class="w-6 h-6 flex items-center justify-center rounded bg-indigo-500 text-white hover:bg-indigo-700 text-xs" title="Stabile successivo">
<svg xmlns="http://www.w3.org/2000/svg" class="icon icon-tabler icon-tabler-chevron-down" width="18" height="18" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><path stroke="none" d="M0 0h24v24H0z" fill="none"/><polyline points="6 9 12 15 18 9" /></svg>
</button>
</div>
<button id="current-stabile" class="flex-1 text-base font-semibold text-gray-900 dark:text-gray-100 bg-transparent hover:bg-yellow-300 dark:hover:bg-gray-700 focus:outline-none focus:ring-2 focus:ring-indigo-500 transition text-center" title="Cambia stabile">
{{ $stabileAttivo ?? "Nessuno Stabile" }}
</button>
</div> </div>
</div> </div>