Commit Graph
37 Commits
Author SHA1 Message Date
davideandClaude Sonnet 5 28a72c80b2 Normalizza il suffisso #AF di ConfigName; documenta il limite sulle family table di assiemi
Test end-to-end su un albero reale (9284218024b.asm, confrontato con la sua
BOM Creo di riferimento tramite scripts/CreoBom.cs) oltre gli 8 campioni usati
per il reverse engineering iniziale.

Trovato: i componenti creati da un pattern/array feature hanno un ConfigName
con suffisso "<codice>#AF<n>" (n = indice nel pattern), non un'istanza di
family table vera - la BOM di Creo lo ignora e unisce le occorrenze duplicate.
AsmRecordReader ora rimuove questo suffisso prima di usare il nome istanza.

Trovato ma non risolto: un intero ASSIEME (non solo le parti normalizzate)
puo' avere una family table, risolta da Creo con un meccanismo diverso da
ConfigName (non decodificato). AsmRecordReader non lo rileva e non lancia
eccezione in questo caso: il fallback automatico di Form1 non scatta, e il
risultato puo' essere silenziosamente incompleto. Documentato come limite
noto in formato-asm-record.md e in CLAUDE.md - nessun fix applicato finche'
il meccanismo non e' meglio compreso.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-09-21 16:27:15 +02:00
davideandClaude Sonnet 5 cce377a091 Integra il parser esatto del .asm nella GUI (fase 4 e 5)
AsmRecordReader (spostato da scripts/CreoBom.cs nel progetto principale,
unica fonte di verita' condivisa con lo script via #:project) sostituisce
AssemblyComponentScanner in Form1.RisolviAlberoComponenti (fase "Trova
componenti referenziati") e AssiemeCompleto (fase "Verifica completezza"):
legge esattamente la sezione "members" del binario invece di contare
occorrenze testuali, eliminando i falsi positivi/negativi noti dell'euristica
(riferimenti fantasma, placement senza suffisso, ecc.).

Se un file non rispetta il formato validato (InvalidDataException, coperto
solo dagli 8 campioni usati per il reverse engineering) Form1 ripiega
sull'euristica di AssemblyComponentScanner, che resta quindi come fallback
e come fonte di verita' per gli script BomViaDb.cs/ExtractCreoStrings.cs.

Aggiunti test per AsmRecordReader (fixture binarie costruite a mano: lettura
membri, risoluzione ConfigName, conteggio disallineato, sezione assente).
Aggiornata la documentazione (CLAUDE.md, docs/architettura.md,
docs/formato-asm.md, docs/formato-asm-record.md) di conseguenza.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-09-21 16:14:00 +02:00
davideandClaude Sonnet 5 60dfd26e8b Snellisci CLAUDE.md: rimuovi duplicazione con docs/architettura.md e db-cad-index.md
La sezione Architettura ripeteva quasi verbatim il dettaglio file-per-file
gia' in docs/architettura.md e docs/db-cad-index.md, gonfiando il contesto
caricato in ogni sessione senza aggiungere informazione. Sostituita con un
riepilogo delle 5 fasi del wizard e rimandi puntuali; nessun contenuto perso,
solo spostato dove viveva gia' in dettaglio.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-09-21 15:41:22 +02:00
davideandClaude Sonnet 5 35009b5cd3 Aggiungi CreoBom.cs: parser esatto del formato .asm via record binari
Porting C# del reverse engineering della struttura a record del .asm Creo
(sezione "members" + parametro "ConfigName" per le family table): legge
esattamente i componenti diretti e genera la stessa BOM esportata da Creo,
senza le euristiche testuali (conteggio occorrenze) di AssemblyComponentScanner.
Resta uno script di analisi indipendente, non integrato nella GUI.

Aggiorna anche formato-asm.md (non e' piu' vero che "non esiste un parser
strutturale") e architettura.md (script mancante nell'elenco).

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-09-21 15:41:14 +02:00
davideandClaude Sonnet 5 3cfc040fb0 Aggiungi documentazione tecnica su cad_index.db
Schema, logica di scansione/upsert incrementale di Indexer.ScanAsync,
come l'app individua il DB all'avvio (incluso il caveat sulla cartella
di build in dev) e le query piu' usate.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-09-21 14:37:08 +02:00
davideandClaude Sonnet 5 3ea582e645 Usa la cartella del DB come fallback per la cartella di lavoro
Se non c'e' una cartella di lavoro salvata (o punta a una cartella
cancellata), AppContext.BaseDirectory finiva spesso nella cartella di
build (bin/Release/...) invece che dove l'utente tiene effettivamente
il proprio lavoro. Ora il fallback usa la cartella del DB caricato.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-09-21 14:33:18 +02:00
davideandClaude Sonnet 5 9ecdccb6bb Migliora UI: finestra aggiornamento indice, barra nav wizard, fase Verifica
- ProgressForm: gerarchia visiva, contrasto testo, barra piatta blu al posto
  della ProgressBar nativa verde, footer separato dal bottone Annulla.
- Barra Avanti/Indietro: footer separato con linea, padding allineato ai
  pannelli di ogni fase, riordinata sopra la barra di stato come convenzione
  standard invece che sotto.
- Fase 5 (Verifica completezza): bottone principale reso primario, lista
  file .asm passata da griglia di icone troncate a lista a riga singola
  leggibile.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-09-21 14:16:32 +02:00
davideandClaude Sonnet 5 5c9661eb12 Fix euristica BOM, unifica script/GUI su un'unica fonte, aggiungi test integrazione/E2E
Due bug reali trovati confrontando l'estrazione BOM con la BOM ufficiale Creo:
un componente scartato per placement fallito in un file veniva bloccato per
sempre anche quando il file giusto aveva un vero placement (perdendo interi
sotto-alberi come 9256510047), e i codici con suffisso (_C01 ecc.) richiedevano
sempre placement esplicito invece dell'eccezione per occorrenze ripetute già
presente nella GUI. Entrambi corretti.

AssemblyComponentScanner reso pubblico e scripts/BomViaDb.cs, ExtractCreoStrings.cs
riscritti per referenziarlo via "#:project" invece di duplicare l'euristica:
un'unica fonte di verità condivisa da GUI e script standalone.

Aggiunti test di integrazione per Indexer.ScanAsync (mai coperto oltre al
parsing del nome file) e test end-to-end che ricostruiscono l'intera pipeline
disco -> indice -> risoluzione albero componenti senza toccare la UI.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-09-21 13:43:54 +02:00
davideandClaude Sonnet 5 353a1028d9 Fix icon: bigger logo, uniform white background, better source quality
Regenerated from the last committed (already-transparent) icon instead
of continuing to reprocess an already-degraded local copy, avoiding
further quality loss from repeated extract/recomposite passes.

Two real defects fixed along the way:
- The white background had a faint ghost outline: the transparent
  source still carried a very-low-alpha (~5-9%) remnant of the original
  card's border, invisible on its own but visible once composited onto
  a new solid white background. Added a hard low-alpha cutoff before
  cropping/compositing instead of keeping every non-zero alpha pixel.
- Margin around the logo was too generous (14%), making it look small;
  reduced to 8%, checked against the 16%-radius rounded corners so nothing
  gets clipped.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-09-21 11:41:12 +02:00
davideandClaude Sonnet 5 4d5717f827 Bundle native libraries into the single-file publish
PublishSingleFile alone still left e_sqlite3.dll as a loose file next
to PrepStep.exe; moving just the exe (e.g. copying it elsewhere) broke
SQLite with an opaque SqliteConnection type initializer exception.
IncludeNativeLibrariesForSelfExtract embeds it in the exe instead,
self-extracted to a temp folder at first run, so the published exe is
a genuinely single, movable file.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-09-21 11:30:29 +02:00
davideandClaude Sonnet 5 379deec986 Remove the step_finali copy/report feature
Not needed anymore: the app no longer copies matched .stp files from
step/ into a separate step_finali/ folder, or reports which distinta
codes are still missing a STEP. Removed the "Crea cartella step_finali"
button, GeneraReportStep, and ReportStepForm/EsitoStep. Phase 5 keeps
"Verifica completezza assiemi" and the drag&drop .asm list (still how
files get sent to Creo Distributed Batch); renamed from "Verifica
completezza e STEP" to "Verifica completezza" since it's no longer about
STEP output. PulisciRawEStep now only clears raw/ and step/.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-09-21 11:23:46 +02:00
davideandClaude Sonnet 5 13798ad47c Add explicit working folder; rename project from CadSearchGui to PrepStep
Working folder (phase 1): CSV/raw/step/step_finali all used to live split
across two different implicit locations (CSV in the "repo root" found by
walking up for CLAUDE.md, raw/step next to the input distinta file) with
neither shown to the user. That repo-root lookup also silently breaks once
the app runs as a standalone published exe on a machine with no repo/
CLAUDE.md at all. Replaced both with one explicit "cartella di lavoro",
auto-suggested (last used, remembered the same way as the DB path) and
changeable from phase 1, with no dependency on any repo marker file.

Rename: CadSearchGui was the working name from before the app had a
product identity; renamed folders, csproj files, namespace and the
AppData settings folder to PrepStep throughout, matching the exe name
already in use. Product-facing name stays "Cevolani StepPrep".

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-09-21 11:18:43 +02:00
davideandClaude Sonnet 5 6726dd2216 Add app icon, product name/version, and document them
- New app.ico (from the Cevolani favicon, background made transparent and
  cropped tighter to the logo so it stays legible at 16/24px), wired up via
  ApplicationIcon in the csproj and re-read at runtime for the window icon.
- Named the product "Cevolani StepPrep" and set Version=0.1.0 in the csproj;
  shown in the window title. The CadSearchGui folder/namespace/csproj keep
  their technical name, only the product-facing name changed.
- Updated CLAUDE.md, README.md and docs/architettura.md to reflect the
  product name/version, UiStile.cs, app.ico, and that this app is a
  pre-process step ahead of Creo Distributed Batch.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-09-21 11:00:01 +02:00
davideandClaude Sonnet 5 ba18d682f3 Fix overflowing/clipped UI text and give buttons a consistent flat style
Instruction and status labels used AutoSize/fixed widths with no wrap
constraint, so long Italian paragraphs and network paths ran past the
window edge or got clipped instead of wrapping. Report dialogs had
fixed-height labels that clipped multi-line text. ProgressForm's folder
label could overflow its non-resizable dialog.

- Labels now wrap responsively (TableLayoutPanel column at 100% + Dock=Top)
  instead of a fixed pixel cap, so they reflow when the window is resized.
- Report dialog labels switched from fixed Height to AutoSize.
- ProgressForm's folder label truncates with ellipsis + tooltip, matching
  the existing pattern used by the import status label.
- Added ApplicationHighDpiMode=PerMonitorV2 to fix control proportions on
  scaled displays.
- Added UiStile.cs: shared flat button style (primary/secondary), rounded
  corners for the wizard nav buttons, and AutoSize+padding on all buttons
  so button size always matches its text (fixes text getting clipped when
  a hardcoded Size was too narrow for the label).
- Fase 5's drag&drop .asm list now fills available vertical space instead
  of a fixed 680x160 box.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-09-21 10:40:32 +02:00
davideandClaude Sonnet 5 6511d58b01 Parallelize raw/ copy and document overall architecture
CopiaFileTrovati now copies with Parallel.ForEach (degree 6) instead of
sequentially: the bottleneck is network latency to the share, not CPU,
so overlapping copies gives a large speedup (~5x in a synthetic
benchmark with simulated SMB latency, documented in
docs/copia-raw-parallela.md).

Also adds docs/architettura.md, a full architecture overview of every
source file, the wizard's 5 phases, dialogs, persistence and standalone
scripts.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-09-21 10:07:46 +02:00
davideandClaude Sonnet 5 0966e66232 Add drag&drop .asm preview and force CSV output to repo root
Fase 5 now shows the distinta's .asm files already copied to raw/ as
draggable icons, so they can be dropped straight onto Creo or Explorer
without re-hitting the DB/share. The CSV from fase 2 is now always
written to the repo root (found by walking up to CLAUDE.md) instead of
next to the input file, wherever that happens to be.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-09-21 09:54:06 +02:00
davideandClaude Sonnet 5 8a8a7d0417 Recognize commercial parts with alphabetic names in .asm scanning
Pro-E numeric codes cover most components, but parts downloaded as STEP
from online catalogs (rings, bushings, knobs...) get alphabetic Creo names
with no predictable shape. Add a second extraction path that tokenizes the
binary generically and validates candidates against the known codes in
cad_index.db, applying the same placement/occurrence rule used for bare
numeric codes. Numeric extraction is unchanged, so missing-from-index
reporting for renamed/moved Pro-E codes still works.

Also load all known prt/asm codes once per scan instead of one query per
candidate, in both RisolviAlberoComponenti and VerificaCompletezzaAssiemi.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-09-18 08:41:01 +02:00
davideandClaude Sonnet 5 c75dd21551 Exclude temp_* root folders from the CAD index
temp_paris, temp_davide, temp_studi esterni and the other temp_* folders
are personal/scratch work areas on the share: they hold stale or unrelated
copies of codes that also exist in the official project folders, and a real
.asm can numerically coincide with an unrelated file living in one of these
(see docs/formato-asm.md, the 2502020809 false-positive pulling in an
unrelated machine's assembly from temp_studi esterni/Slitter CD549).

Scan now deletes any already-indexed temp_* rows up front and skips walking
those folders going forward, so downstream queries (Form1.cs, ExtractCreoStrings.cs)
never need to filter them out case by case.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-09-17 16:19:37 +02:00
davideandClaude Sonnet 5 e7b5d85f6b Add family_name and bracket-adjacent placement signals for .asm scanning
Two more real placement forms found by comparing against Creo BOM reports:

- A sub-assembly can be referenced only through a "family_name\0<code>\0"
  metadata field instead of a textual "Componente ID" placement or the
  doubled-NUL pattern (case 9284202452 inside 9284208188_D400.asm, which
  contains 9284202452_C01/_C02/_C03 - previously dropped entirely, along
  with its three children).
- A bare numeric code immediately followed by a family-table bracket
  (<code><GENERIC>, e.g. bearing instances like 2510060303<CUSCI_ACBB7>)
  is a real reference to that instance, even though only the generic file
  is indexed on disk. Previously the instance code silently vanished before
  ever reaching the DB lookup; now it survives placement filtering and ends
  up in the "scartati" (discarded) list instead, so it's traceable rather
  than invisible.

docs/formato-asm.md documents both, bringing the total to four recognized
placement forms.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-09-17 16:14:52 +02:00
davideandClaude Sonnet 5 a7e0df0247 Fix runaway recursion and two missed-component gaps in .asm scanning
The bare root code of an assembly (e.g. 9284208188, without a _D... suffix)
is always referenced inside its own suffixed sub-assemblies as a genuine
placement pointing back to the general assembly. Following it during
recursive resolution pulled in the entire product tree instead of just the
requested sub-assembly (598 components collected instead of ~65 on
9284208188_D600). Fixed by seeding the visited-codes set with each starting
assembly's root code, in both scripts/ExtractCreoStrings.cs and the two BFS
call sites in Form1.cs (RisolviAlberoComponenti, AssiemeCompleto).

Also closes two recall gaps found by comparing against a real Creo BOM
report: some real placements only show up as the code repeated twice
separated by a NUL byte rather than the usual "Componente ID N (...)" text,
and family-table bearing codes (CUSCI_...) use the same <...> bracket
convention as UNI hardware but weren't recognized.

docs/formato-asm.md documents all three findings.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-09-17 15:32:55 +02:00
davideandClaude Sonnet 5 9660c4883d Refine .asm component extraction: batch DB queries, wider suffix regex, placement check
- Batch the DB lookup per file instead of per code in scripts/ExtractCreoStrings.cs:
  files_ultima_versione is an unmaterialized view, so each query rescanned the whole
  files table (~230ms) - batching cuts a multi-minute BFS to seconds.
- Widen the code regex to accept a revision letter and a "_..." suffix together
  (e.g. "9284200366A_C01"), and purely numeric "_NNNN" suffixes (e.g. dimensional
  variants like "2702220182_8188"), not just letter+digits.
- Require bare digit-only candidates to also appear inside a real
  "Componente ID N (...)"/"Component id N (...)" placement, filtering out
  incidental references to a containing assembly's own code.
- scripts/ExtractCreoStrings.cs now reports only the direct references of the given
  .asm (one level, matching Creo's own tree for that file) instead of recursing into
  sub-assemblies.
- Port the regex and placement-check refinements to the production
  AssemblyComponentScanner.cs used by the app's "Trova componenti referenziati" and
  "Verifica completezza" phases.
- Document the new false-positive categories (parent/container self-reference,
  suppressed/removed components with residual placement, placement missing
  suffix/bracket detail) in docs/formato-asm.md, generalized beyond the specific
  assemblies used to find them.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-09-17 14:59:23 +02:00
davideandClaude Sonnet 5 e6de563f60 Distinguish missing STEP from missing CAD source in the final report
A component with no .stp could mean two different things: the CAD source
was never found in the index at all, or it's indexed but nobody exported
the STEP yet. Cross-references the missing codes against cad_index.db
(reusing the phase-2 verification cache when available) and reports each
as EsitoStep.StepMancante vs ComponenteNonTrovato, colored differently.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-09-17 13:24:25 +02:00
davideandClaude Sonnet 5 1f6cb2da00 Limit step_finali to the BOM's own components
Sub-components discovered recursively in phase 4 exist only to complete
raw/, not to define what final STEP files are expected - including them
made step_finali report unrelated sub-parts as missing/created. Also drops
the now-unused _componentiRisolti field.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-09-17 12:26:39 +02:00
davideandClaude Sonnet 5 338a7327a0 Resolve UNI family-table hardware (screws/nuts/washers) as components
These appear in the .asm binary as a family-table instance name (e.g.
"R6--_-_U6592<UNI6592>"), not a separate file on disk - only the generic
"uni6592.prt" is actually indexed. Extract just the "<UNI...>" content
instead of the full instance name, in both the standalone script and the
production scanner, so standard hardware stops being silently dropped as
"not found in index".

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-09-17 12:26:31 +02:00
davideandClaude Sonnet 5 52d126372d Redesign the final STEP phase to build a step_finali folder
Previously it only compared the top-level BOM against step/ and reported
matches, without copying anything. Now it unions the BOM codes with the
sub-components resolved in phase 4, copies every matching .stp into a new
step_finali/ folder, and reports what got created vs what's still missing.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-09-17 10:23:35 +02:00
davideandClaude Sonnet 5 ee408219bd Show a progress dialog while resolving referenced components
"Trova componenti referenziati" ran the recursive BFS synchronously on the
UI thread with no feedback. Runs it on a background task instead and shows
a modal dialog with a percentage bar, updated as each .asm in the queue is
processed.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-09-17 09:55:14 +02:00
davideandClaude Sonnet 5 bb99c4f4c5 Apply the ModelView# false-positive fix to the production scanner
The standalone script already excluded internal saved-view IDs
(ModelView#<numero>) from the referenced-codes heuristic; the app's own
"Trova componenti referenziati" phase used the same regex without the fix.
Ports the lookbehind so both stay consistent, per docs/formato-asm.md.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-09-17 09:55:06 +02:00
davideandClaude Sonnet 5 4a3f0a4cf8 Cache DB verification result and reuse it when creating the raw folder
Avoids re-running the same lookup against cad_index.db twice when the
user already clicked "Verifica presenza nel DB" before "Crea cartella raw".

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-09-17 09:13:38 +02:00
davideandClaude Sonnet 5 b77ec39c5b Add DB presence check button to import phase
Lets the user spot missing components right after import instead of
discovering it later in the raw-folder step, by coloring each grid row
green/red based on a lookup against cad_index.db.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-09-17 09:08:33 +02:00
davideandClaude Sonnet 5 f28cb818bd Add standalone .asm BOM-extraction scripts and format documentation
Reverse-engineered the Creo .asm binary format enough to extract referenced
component codes via a text heuristic, mirroring AssemblyComponentScanner's
approach and Form1's recursive resolution against cad_index.db. Documents
known false-positive classes (ModelView# view IDs, self-references, and
phantom references to superseded/renamed codes).

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-09-17 09:01:45 +02:00
davideandClaude Sonnet 5 52483177f0 Add wizard UI, general-assembly resolution, and test suite
Restructure Form1 into a sequential wizard (database -> import -> raw ->
recursive component resolution -> completeness/STEP report), fix
case-sensitivity bugs in codice/tipo_file lookups and a word-boundary gap
in the assembly scanner that missed _D100-style sub-assembly references,
and treat the distinta's general assembly as an ordinary CSV row (derived
from the DBP_<codice>_<timestamp> filename) instead of special-casing it
throughout. Also adds CadSearchGui.Tests (xUnit) covering the scanner,
filename parsing, and the case-insensitive DB lookup behavior.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-09-16 16:25:52 +02:00
davideandClaude Sonnet 5 146ce78eae Index Unificati/Commerciali, merge cleanup buttons, report unmatched components
- Add 'Unificati' and 'Commerciali' as indexed root folders alongside the
  existing four, updating Indexer.CartelleRadice and the docs.
- Replace the separate "Pulisci cartella raw" / "Pulisci cartella step"
  buttons with a single "Pulisci raw e step" that clears both under one
  confirmation; falls back to a folder picker when no path is known yet
  in the session instead of staying disabled.
- "Trova componenti referenziati" now also writes a persistent summary
  (PRT/sub-assemblies found and copied, codes not found) to the main
  window's status line, not just the popup dialog, and reports clearly
  when no database is loaded instead of failing silently.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-09-16 12:05:07 +02:00
davideandClaude Sonnet 5 e56a3be5b4 Add recursive component resolution for assembly dependencies
Assemblies reference other assemblies and parts internally; a flat
single-level copy into raw/ left Creo unable to load models ("Dati di
input non completi"). AssemblyComponentScanner heuristically extracts
component codes embedded as readable strings inside the otherwise
binary .asm files; each candidate is validated against the index (which
filters out scan noise), copied into raw/, and if it's itself an
assembly, queued for the same treatment until the whole tree resolves
to PRT leaves. PrtMancantiForm reports what was found and copied.

Also ignore Creo Distributed Batch job files (*.dxc).

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-09-16 11:40:34 +02:00
davideandClaude Sonnet 5 97d53a16dd Add raw-folder step, redesign UI, remember last DB path, add README
- Split the import flow into explicit steps: import/preview CSV, then a
  separate "Crea cartella raw" button that looks up CAD paths and copies
  matched files into raw/ next to the source distinta file.
- Redesign the top panel with grouped, auto-sized sections (database vs.
  import) instead of hand-tuned row heights, fixing overlap/clipping bugs;
  style the primary action button and polish the results grid.
- Remember the last successfully loaded database path in
  %AppData%\CadSearchGui\ultimo_db.txt so it reloads automatically on
  future launches regardless of the working directory.
- Ignore the /step/ working folder.
- Add a README with build/run/publish instructions and project overview.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-09-16 10:59:16 +02:00
davideandClaude Sonnet 5 98c513dd64 Replace CAD search tab with CAD-path lookup for imported components
Drop the free-text search UI; the single remaining view imports the
Distinta Base, generates the CSV, and looks up each Componente code in
the indexed DB (files_ultima_versione, prt/asm) to show its CAD file
path directly in the results grid.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-09-16 10:28:15 +02:00
davideandClaude Sonnet 5 f88639bf4b Add Distinta Base import tab: parse .xls/.xml export to CSV with preview
Reads the ERP-exported "Distinta Base" file (SpreadsheetML XML or real
binary .xls/.xlsx via ExcelDataReader), extracts Componente/Descrizione,
writes a CSV and previews it in a new tab alongside the existing CAD
search. Also ignore the exported Excel/CSV files dropped in the repo root.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-09-16 10:22:16 +02:00
davideandClaude Sonnet 5 82a69e0d20 Add CadSearchGui: WinForms app to index and search the CAD archive
Indicizza le cartelle __Accessori, __B.end, __Corpi, __Fondi in un DB
SQLite locale ed espone una GUI di ricerca (codice, tipo, cartella,
solo ultima versione) con aggiornamento incrementale dell'indice e
stima del tempo rimanente.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-09-16 09:58:55 +02:00