feat: wire offer→project phases/tasks, redo Offerte tab, cleanup project tabs

- importOfferIntoProject(): materializes project phases/tasks from the assigned
  tier's services grouped by services.fase (merge-by-title, dedup tasks)
- assignOfferToProject: optional import_phases flag triggers the import
- getProjectFullDetail: projectOffers/availableMicros now include macro name +
  tier_letter (dropdown shows "Offerta — Tier X"); availableMicros filters
  non-archived macros
- OffersTab redone: shows macro + tier badge, "Importa fasi e task" checkbox
- removed project "Preventivo" tab + deleted QuoteTab.tsx (legacy quote_items)
- sidebar: Lead before Clienti
- no DB migration (reuses existing tables)

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
2026-06-22 09:08:28 +02:00
parent f5f90cd643
commit 1824cb643f
7 changed files with 169 additions and 369 deletions
+12 -6
View File
@@ -4,8 +4,8 @@ milestone: v2.3
milestone_name: Email & Accesso
status: planning
stopped_at: ""
last_updated: "2026-06-21T11:05:00.000Z"
last_activity: 2026-06-21 -- Roadmap v2.3 created (Phases 23-25)
last_updated: "2026-06-22T09:00:00.000Z"
last_activity: 2026-06-22 -- Lead→Cliente (A+B) in prod; cleanup tab progetto + offerta→fasi in corso
progress:
total_phases: 3
completed_phases: 0
@@ -26,10 +26,16 @@ See: .planning/PROJECT.md (updated 2026-06-21)
## Current Position
Phase: Not started
Plan:
Status: Roadmap created, ready to plan Phase 23
Last activity: 2026-06-21Roadmap v2.3 created (Phases 2325, 9 requirements mapped)
Phase: Pre-23 fixes & flow wiring (fuori roadmap formale)
Plan: `.claude/plans/te-li-scrivo-tutti-lucky-hearth.md`
Status: In esecuzione — cleanup tab progetto + collegamento offerta→fasi/task
Last activity: 2026-06-22Lead→Cliente consegnato in prod
### Lavoro recente (pre-fase-23, in prod)
- **Tassonomie**: gestione centralizzata categorie/tag in Impostazioni (modello Notion, pool persistenti, `src/lib/taxonomy.ts`).
- **Lead → Cliente (A+B)**: campi `clients.email/phone` + `leads.archived` (migrazione 0011 applicata a prod); `convertLeadToClient` (riusa `createClientCore`, porta i transcript, archivia il lead mantenendo "won"); tasto Converti/Convertito; lead archiviati nascosti da lista/kanban.
- **In corso**: rimozione tab Preventivo dal progetto, riordino sidebar, tab Offerte rifatta, import offerta→fasi/task per `services.fase`.
### Fasi completate (v2.2, storico)