{{-- TOP TOOLBAR: FORNITORE CONTEXT & QUICK SYNC BUTTONS --}}
TR

TecnoRepair Pro 4.5 — Gestione Pratiche Riparazione

Fornitore operativo: {{ $this->fornitoreLabel ?? 'Nethome' }}

@if(count($this->fornitoriOptions) > 1)
@endif 🔍 Ricerca Seriali 📦 Catalogo & Ricambi
{{-- SUMMARY KPI CARDS --}}
Totale Schede
{{ number_format($this->totals['totale'] ?? 0, 0, ',', '.') }}
In Lavorazione
{{ number_format($this->totals['aperte'] ?? 0, 0, ',', '.') }}
Riparate
{{ number_format($this->totals['riparate'] ?? 0, 0, ',', '.') }}
Rottamate / Ricambi
{{ number_format($this->totals['rottamate'] ?? 0, 0, ',', '.') }}
Reso Fornitore / RMA
{{ number_format($this->totals['rma_garanzia'] ?? 0, 0, ',', '.') }}
{{-- FILTRI PER RICERCA SCHEDE (FEDELE AL DESKTOP TECNOREPAIR) --}}
🎛️ FILTRI per Ricerca Schede Standard TecnoRepair
-
{{-- GRIGLIA ELENCO SCHEDE (COLORAZIONE FEDELE A TECNOREPAIR) --}}
Schede Elencate: {{ count($this->rows) }} (visualizzate prime 120 per reattività)
Riparato Irreparabile / Rottamato Accettazione Attesa / Laboratorio
@forelse($this->rows as $r) @php $rowBg = match($r['row_color']) { 'green' => 'bg-emerald-50/80 hover:bg-emerald-100/90 text-emerald-950 font-medium', 'red' => 'bg-rose-50/80 hover:bg-rose-100/90 text-rose-950 font-medium', 'blue' => 'bg-sky-50/80 hover:bg-sky-100/90 text-sky-950', 'amber' => 'bg-amber-50/80 hover:bg-amber-100/90 text-amber-950', default => 'bg-white hover:bg-slate-50 text-slate-800', }; $borderLeft = match($r['row_color']) { 'green' => 'border-l-4 border-l-emerald-600', 'red' => 'border-l-4 border-l-rose-600', 'blue' => 'border-l-4 border-l-sky-600', 'amber' => 'border-l-4 border-l-amber-600', default => 'border-l-4 border-l-transparent', }; @endphp @empty @endforelse
Num Ingresso Cliente Telefono Difetto Segnalato Marca Modello Seriale / IMEI Cod. Prod Ricons. Stato Riparazione Operatore Azione
{{ $r['numero_scheda'] }} {{ $r['ingresso'] }} {{ $r['cliente'] }} {{ $r['telefono'] }} {{ $r['difetto'] }} {{ $r['marca'] }} {{ $r['modello'] }} {{ $r['seriale'] }} {{ $r['cod_prodotto'] }} @if($r['riconsegnato']) SI @else - @endif {{ $r['stato_rip'] }} {{ $r['operatore'] }}
Nessuna scheda trovata con i filtri correnti. Prova a cliccare "Reset Tutti i Filtri" o "Sincronizza MDB".
{{-- SCHEDA APPARECCHIO MODAL / DETTAGLIO INTERATTIVO (7 TABS TECNOREPAIR) --}} @if($this->selectedSchedaId && $this->activeScheda)
{{-- MODAL HEADER --}}
SCHEDA #{{ $this->activeScheda['numero_scheda'] }}

{{ $this->activeScheda['marca'] }} {{ $this->activeScheda['modello'] }} ({{ $this->activeScheda['seriale'] }})

Cliente: {{ $this->activeScheda['cliente_nome'] }} — Ingresso: {{ $this->activeScheda['data_ingresso'] }}

{{ $this->activeScheda['stato_rip'] }}
{{-- TAB BAR --}}
@php $tabsMap = [ 'entrata' => '1. Apparecchio in Entrata', 'riparazione' => '2. Riparazione & Flussi ⚡', 'ricambi' => '3. Ricambi Utilizzati', 'preventivo' => '4. Preventivo - Costi - DDT', 'annotazioni' => '5. Annotazioni & Cortesia', 'comunicazioni' => '6. Comunicazioni', 'cq' => '7. Controllo Qualità (C.Q.)', ]; @endphp @foreach($tabsMap as $tKey => $tLabel) @endforeach
{{-- TAB CONTENTS --}}
{{-- TAB 1: APPARECCHIO IN ENTRATA --}} @if($this->schedaTab === 'entrata')
👤 Dati Cliente
{{ $this->activeScheda['cliente_nome'] }}
Tel: {{ $this->activeScheda['cliente_telefono'] }}
Email: {{ $this->activeScheda['cliente_email'] }}
Indirizzo: {{ $this->activeScheda['cliente_indirizzo'] }}, {{ $this->activeScheda['cliente_citta'] }}
💻 Dati Apparecchio
Tipo: {{ $this->activeScheda['tipo_apparecchio'] }}
Marca: {{ $this->activeScheda['marca'] }}
Modello: {{ $this->activeScheda['modello'] }}
Codice Prodotto: {{ $this->activeScheda['codice_prodotto'] }}
Seriale 1: {{ $this->activeScheda['seriale'] }}
@if($this->activeScheda['seriale_2'] !== '-')
Seriale 2: {{ $this->activeScheda['seriale_2'] }}
@endif
🔐 Sicurezza & Accesso
Codice PIN: {{ $this->activeScheda['codice_pin'] }}
Codice Sblocco: {{ $this->activeScheda['codice_sblocco'] }}
Tecnico Assegnato: {{ $this->activeScheda['tecnico'] }}
Accessori Consegnati: {{ $this->activeScheda['accessori'] }}
⚠️ Difetto Segnalato dal Cliente

{{ $this->activeScheda['difetto'] }}

🔍 Stato Generale Apparecchio

{{ $this->activeScheda['stato_generale'] }}

@endif {{-- TAB 2: RIPARAZIONE & FLUSSI AUTOMATIZZATI --}} @if($this->schedaTab === 'riparazione')
⚡ FLUSSI AUTOMATIZZATI DI CHIUSURA PRATICA
{{-- 1. FLUSSO RIPARATO --}}
1

Apparato Riparato

Imposta stato a RIPARATO (4), data chiusura a oggi e prepara per riconsegna cliente.

{{-- 2. FLUSSO ROTTAMAZIONE / RICAMBI --}}
2

Rottamazione / Ricambi

Imposta stato a IRRIPARABILE o destina a pezzi di ricambio interni.

{{-- 3. FLUSSO RESO FORNITORE (RMA) --}}
3

Reso Fornitore (RMA)

Invia apparato in garanzia/RMA a fornitore (es. NCOM SRL) con tracking del seriale.

🛠️ Descrizione Lavorazione Effettuata

{{ $this->activeScheda['descrizione_lavorazione'] }}

@endif {{-- TAB 3: RICAMBI UTILIZZATI --}} @if($this->schedaTab === 'ricambi')
📦 Componenti & Ricambi Collegati alla Scheda
@if(!empty($this->activeScheda['ricambi']))
@foreach($this->activeScheda['ricambi'] as $item) @endforeach
Codice Ricambio Descrizione ID Riferimento
{{ $item['CodiceRicambio'] ?? '-' }} {{ $item['Descrizione'] ?? 'Ricambio collegato' }} {{ $item['ID'] ?? '-' }}
@else
Nessun ricambio specifico registrato per questa pratica. Puoi cercarli nel Catalogo Ricambi.
@endif
@endif {{-- TAB 4: PREVENTIVO - COSTI - DDT --}} @if($this->schedaTab === 'preventivo')
Costo Subito / Sostenuto
{{ number_format($this->activeScheda['costo_subito'], 2, ',', '.') }} €
Costo Addebitato Cliente
{{ number_format($this->activeScheda['costo_addebitato'], 2, ',', '.') }} €
Acconto Ricevuto
{{ number_format($this->activeScheda['acconto'], 2, ',', '.') }} €
Preventivo Iniziale
{{ number_format($this->activeScheda['preventivo'], 2, ',', '.') }} €
@endif {{-- TAB 5: ANNOTAZIONI & ALLEGATI --}} @if($this->schedaTab === 'annotazioni')
📎 File Allegati & Fotografie
@if(!empty($this->activeScheda['allegati']))
@foreach($this->activeScheda['allegati'] as $all)
{{ $all['nome'] }} allegato
@endforeach
@else

Nessun file o foto allegata a questa pratica.

@endif
@endif {{-- TAB 6: COMUNICAZIONI --}} @if($this->schedaTab === 'comunicazioni')
💬 Storico Comunicazioni con il Cliente
{{ $this->activeScheda['comunicazioni'] ?: 'Nessuna comunicazione registrata.' }}
@endif {{-- TAB 7: C.Q. CONTROLLO QUALITA --}} @if($this->schedaTab === 'cq')
✅ Checklist Standard Controllo Qualità
@endif
{{-- MODAL FOOTER --}}
Pratica gestita da: {{ $this->activeScheda['tecnico'] }}
@endif