Correggo documentazione: sync CSI e risultato scout non persistiti server-side
Il CLAUDE.md e la memory affermavano una sincronizzazione CSI e una persistenza server-side dei risultati partita che non esistono nel codice: la classifica è un array hardcoded (demo) e il risultato scoutato vive solo nel localStorage di chi segna.
This commit is contained in:
@@ -92,8 +92,13 @@ load-bearing, not style preferences:
|
|||||||
- Stats/badges/standings are "write once, read many": computed and persisted once (e.g. at match
|
- Stats/badges/standings are "write once, read many": computed and persisted once (e.g. at match
|
||||||
end), never recomputed on every page open.
|
end), never recomputed on every page open.
|
||||||
- Live match scouting: only the scoring user writes; everyone else reads already-saved data.
|
- Live match scouting: only the scoring user writes; everyone else reads already-saved data.
|
||||||
- CSI league data is synced periodically server-side into a local table; the app only ever reads
|
- CSI league data is currently a **hardcoded placeholder** array in `src/lib/crapp-data.ts`
|
||||||
from the internal DB, never the CSI site directly.
|
(`classifica`, `storicoMatch`), explicitly marked "(demo)" in the UI — no real sync exists yet,
|
||||||
|
this is planned/open work, not an existing pattern to copy.
|
||||||
|
- A scouted match result (`ScoutMatch`, from `scout.tsx` / `scout-store.ts`) is saved **only to
|
||||||
|
the scoring device's `localStorage`** (key `crapp-scout-v1`), never to Supabase — only the
|
||||||
|
in-progress resume state goes to the `scout_live` table. So today a match result is not shared
|
||||||
|
across devices/users at all.
|
||||||
- Push notifications only for high-value events (convocations, training/match reminders, ball-duty
|
- Push notifications only for high-value events (convocations, training/match reminders, ball-duty
|
||||||
turn, final result) — no chat/photo/video features.
|
turn, final result) — no chat/photo/video features.
|
||||||
|
|
||||||
|
|||||||
@@ -8,7 +8,7 @@ type: feature
|
|||||||
- Dopo una mutazione aggiornare la cache con `setQueryData`, non `invalidateQueries` (evita riletture).
|
- Dopo una mutazione aggiornare la cache con `setQueryData`, non `invalidateQueries` (evita riletture).
|
||||||
- Scout live: scrive solo l'utente che segna; gli altri leggono dati già salvati.
|
- Scout live: scrive solo l'utente che segna; gli altri leggono dati già salvati.
|
||||||
- Statistiche, badge e classifiche: "write once, read many" — calcolate e salvate una volta a fine partita, mai ricalcolate a ogni apertura pagina.
|
- Statistiche, badge e classifiche: "write once, read many" — calcolate e salvate una volta a fine partita, mai ricalcolate a ogni apertura pagina.
|
||||||
- Dati CSI: sincronizzazione periodica server-side salvata su tabella locale; l'app legge solo dal database interno.
|
- Dati CSI: al momento è un array hardcoded in `src/lib/crapp-data.ts`, marcato "(demo)" in UI — nessun sync reale, da implementare. Anche il risultato di una partita scoutata (`ScoutMatch`) oggi vive solo nel `localStorage` del dispositivo di chi scouta, non su Supabase.
|
||||||
- Push solo per eventi importanti: convocazioni, promemoria allenamento/partita, turno palloni, esito finale.
|
- Push solo per eventi importanti: convocazioni, promemoria allenamento/partita, turno palloni, esito finale.
|
||||||
- Niente foto/video/chat o funzionalità pesanti.
|
- Niente foto/video/chat o funzionalità pesanti.
|
||||||
- Schema target: team_id, eventi, presenze, azioni_scout, statistiche_aggregate, classifica_csi, notifiche, con indici sui campi di filtro/relazione.
|
- Schema target: team_id, eventi, presenze, azioni_scout, statistiche_aggregate, classifica_csi, notifiche, con indici sui campi di filtro/relazione.
|
||||||
|
|||||||
Reference in New Issue
Block a user