Pagina repo-ului arăta README-ul generic roa2web și nu explica ce e
diferit / ce se urmărea. README-ul nou pune scopul pe prima pagină:
prototip de probă „web (Python/Vue) conduce business logic Oracle prin
PL/SQL", driver-ul de risc-talent VFP, cele 6 ipoteze, scope wall,
relația cu roa2web, stare WIP.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Fork complet din roa2web @ b0f4800 + modulul service-auto. Domeniu
distinct (gestiune comenzi atelier auto). Stare WIP la desprindere
(f115b5e). Vezi roa2web docs/prd/prd-0.6-audit-service-auto.md.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Migrare completă de la SP_CREEAZA_COMANDA_PROTOTIP la PACK_AUTO.dev_adauga_lucrare (18 params).
Formular ComandaNoua extins cu toate câmpurile din SP: observații, defecțiuni, km, ore motor, termen, nr. dosar.
- schema: solicitari → observatii (opțional); adăugat defectiuni, km_int, ore_functionare, nr_dosar, termen
- service: callproc cablat pe câmpurile noi; pc_nr cu milisecunde (evită colizii sub-secundă)
- error mapper: range 20001→20000 (ORA-20000 era neacoperit → 500 în loc de 422)
- onboarding_roa_web.sql: grant pe PACK_AUTO (înlocuiește SP prototip)
- ComandaNoua.vue: InputNumber km/ore, Calendar termen, Textarea defecțiuni, InputText nr_dosar
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
ORA-01438 (value larger than column precision) apare când
id_masiniclient depășește precizia coloanei Oracle. Este eroare
de input, nu server error — mapăm la 422 Unprocessable.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Linkurile Comenzi + Comandă Nouă lipseau din menu.js — adăugate în
secțiunea dedicată 'Service Auto' (înainte de Sistem).
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Vue Router 4 cu rută parent fără `component` nu știe în ce <router-view>
să randeze copiii. Soluție: ComenziBrowse și ComandaNoua devin rute
top-level (același pattern ca /dashboard).
Descoperit în QA P2.5: URL-ul era corect (/service-auto/comenzi) dar
conținutul era blank — PWA service worker servea cache vechi, ascunzând
bug-ul de router.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
ComandaNoua.vue folosea `primevue/select` (PrimeVue v4+), dar proiectul rulează
pe v3.48.0 unde componenta se numește `Dropdown`. Cauză a erorii 500 la load-ul
rutei /service-auto/comanda-noua: "Failed to resolve import primevue/select".
grants-audit.md: adăugat `GRANT SELECT ON {SCHEMA}.CALENDAR TO ROA_WEB` în
template-ul de onboarding §4.1 și în tabelul sumar §4.5. CALENDAR e accesat de
`shared/routes/calendar.py` pentru period selector-ul din AppHeader — necesar
pe orice server unde userul poate face login, nu doar service-auto.
DBA action separată: `GRANT SELECT ON MARIUSM_AUTO.CALENDAR TO ROA_WEB`.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Add real production sources as authoritative reference (supersedes
vfp_roaauto/Scripturi_instalare/packages.sql which is for a different
product — devize producție, not service auto):
- mariusm_ddl_export.sql: 5127 lines DDL from DBMS_METADATA (tables,
views, triggers) of MARIUSM_AUTO schema
- pack_auto.pck: main business package (17 procedures)
- PACK_FACTURARE.pck, PACK_SESIUNE.pck, PACK_CONTAFIN.pck,
PACK_COMENZI.pck: dependency packages
- export_ddl.sql: SQL export helper using DBMS_METADATA + DBMS_OUTPUT
with discovery via ALL_OBJECTS LIKE patterns
Rewrite tabele-service-auto.md v3 (~600 lines) fully grounded in
production sources. Map all flows end-to-end:
- Create (pack_auto.dev_adauga_lucrare) → NOM_LUCRARI + DEV_ORDL
- Normare (dev_adauga_operatie) → DEV_OPER + DEV_OPER_MECANICI
- Validate ops (dev_valideaza_operatii) → DEV_OPER.VALIDAT
- Validate order (dev_valideaza_comanda) → DEV_ORDL.VALIDAT + CALENDAR
- Archive (dev_arhiveaza_comanda) → DEV_ORDL.INCHIS_FORTAT
- Bonuri consum: generic ROA (ointroduceri.prg tip=3) → RUL.id_lucrare
- Facturare: pack_facturare.* + pack_auto.actualizeaza_deviz
Key business semantics confirmed by Marius 2026-04-11:
- DEV_TIP_DEVIZ.inch_validare = 1 means validation alone closes the
order (no closing note). inch_validare = 0 means additional closing
required (via invoice for billable types, or 711=332 journal entry
for internal types). View AUTO_LISTARE_MAN_TOT_COM has the exact
"closed" condition as (validat=1 AND inch_validare=1) OR
(facturat=1 AND inch_validare=0).
- Live DEV_TIP_DEVIZ values: 1=POST GARANTIE, 2=GARANTIE, 3=REGIE,
4=PREGATIRE, 5=REGIE 2, 6=PRODUCTIE, 7=CONSTATARE. REGIE/PRODUCTIE/
CONSTATARE have inch_validare=1 (internal, closed at validation).
- DEV_OPER for service auto contains only manopera (id_norme). The
id_articol/id_rul_aux columns exist in DDL for another product that
shares the table but are not populated by pack_auto.
- Real materials consumed on an order live in RUL tagged by id_lucrare,
not in DEV_OPER. DEV_ESTIMARI_REP is a separate pre-sale estimate
(both manopera and materiale lines) given to the client, independent
of the real manopera (DEV_OPER) and real materials (RUL).
Plan Correction 13 (claude-main-design-20260411-rethink.md):
- Invalidate Scripturi_instalare references
- Confirm NOM_LUCRARI ← DEV_ORDL inheritance pattern
- Confirm pack_sesiune.dev_idLucrare/dev_idOrdl populated by triggers
- Refine prototype SP (Option 3) template based on real schema
- Timeline unchanged, scope wall reconfirmed
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
plan-design-review pass: 6/10 → 9/10. Added interaction-states table
(6-state PrimeVue spec matching ReceiptCreateUnifiedView.vue toast
conventions), design-system inheritance clause (DESIGN.md/TOKENS/
CSS_PATTERNS), a11y one-liner, week-3 subtask for enum+labels
extraction from VFP source.
Cloned gitea.romfast.ro/romfast/vfp_roaauto and wrote a 300+ line
ground-truth audit (docs/service-auto/tabele-service-auto.md)
covering: DEV_ORDL parent/child inheritance with NOM_LUCRARI,
DEV_TIP_DEVIZ enum (1-7, including user-confirmed Productie/
Constatare for 6/7), dev_adauga_lucrare v1 (pack_devize, 12+1
params, body visible in packages.sql) vs v2 (pack_auto, 17+1,
body only in MARIUSM_AUTO), and the pack_sesiune.dev_idLucrare
trigger/session-state pattern (ROA ERP convention from pre-
RETURNING era, not a bug).
Plan Correction 12 added: the prototype needs a ~40-line SP doing
two INSERTs parent→child with RETURNING id_lucrare (bypassing
pack_sesiune), targeting dev_ordl via nom_lucrari. Original
assumption of a 4-param new SP was wrong. Week 3 subtask updated
to reference the audit draft. ACT/RUL untouched at creation time
— Correction 3 still valid.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
- US-001: mută queue_client.py în data_entry/services/ocr/
- US-002/003/004: oracle_receipt_writer + oracle_server_id în DB
- US-005: receipt_handlers.py (PDF/photo/callback flow)
- US-006: wire handlers în main.py, per-schema connect, seq_cod.nextval
- US-007: .gitignore secrets/*.oracle_pass
- US-008/009/010: teste unit + integration + E2E
- setup-secrets.sh helper + template
- docs/telegram/README.md actualizat cu arhitectura nouă
Testat E2E pe DB live (MARIUSM_AUTO). COD din seq_cod.nextval.
pypdfium2 fallback pentru PDF decode (fără poppler).
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Fix mobile layout issues on /data-entry/create after OCR upload:
- CompactUploadZone action bar forced horizontal on mobile (was stacking
vertically due to global .action-bar column rule in containers.css)
- TOTAL input stretches full width on mobile (was fixed 140px)
- Card/Cash/Alte payment inputs equal width via flex: 1 1 0%
- Extra-small (≤360px) fallback stacks payments vertically
- OCR confidence badges: fixed width (icon-only), hidden percentage text,
hover opacity effect — prevents input misalignment
- OCRConfidenceIndicator: replace hardcoded colors with design tokens
(green-100/800, yellow-100/800, red-100/800), add three-tier dark mode
- Smaller size-small badge variant (border-radius-sm, line-height: 1)
Create docs/DESIGN.md as design source of truth for /design-review,
/plan-design-review, and /frontend-design skills.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Align remaining 12 files with the corrected breakpoint from FINDING-005.
Using < 768 caused a 1px inconsistency at exactly 768px where CSS media
queries (max-width: 768px) triggered mobile but JS did not.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Remove text-transform: uppercase and letter-spacing: 0.05em from
CollapsibleCard and SolduriCompactCard labels. Labels now render
in Title Case as written in source ("Trezorerie" not "TREZORERIE").
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
At exactly 768px, CSS hides desktop header (max-width: 768px) but JS
isMobile used < 768 (strict), so MobileTopBar didn't show either.
Fix: change < 768 to <= 768 across all 5 views (App, Dashboard,
MaturityAnalysis, SettingsHub, DetailedInvoices).
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Sidebar section headings were h3 while page titles are h1, skipping h2.
Change to h2 for proper heading hierarchy (h1 → h2, no skip).
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Add font-variant-numeric: tabular-nums to .metric-value and .stats-value
so financial figures align properly when values change.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Set receipt.value = savedReceipt before router.push() so modeTitle
computes 'Bon #123' even when Vue Router reuses the component instance
and onMounted does not re-run.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
- Fix UnicodeEncodeError in OCR worker subprocesses on Windows: spawned processes
with 'spawn' context inherit charmap (CP1252) encoding, causing crashes when
printing Romanian diacritics (ș, ț, ă) from OCR-extracted text.
Fix: reconfigure sys.stdout/sys.stderr to UTF-8 in _worker_initializer().
- Add *.db-wal and *.db-shm to .gitignore for SQLite WAL mode auxiliary files.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
- Add dedicated FinancialIndicatorsView with its own route
- Refactor FinancialIndicatorsCard: simplified collapsible card (no period picker)
- Dashboard mobile: reduce swipeable pages from 2 to 1, embed indicators in card-0
- Dashboard desktop: wrap indicators in CollapsibleCard
- Update MobileBottomNav defaults: reports-centric nav (Facturi/Banca/Casa/Indicatori)
- BankView/CashView: date format DD/MM/YY, remove amount color classes, CSS tweaks
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
- Persist 2FA state in sessionStorage to survive mobile page reloads
- Reuse existing valid OTP on re-login to avoid rate limiting and duplicate emails
- Add embedded sparkline charts to SolduriCompactCard with expand toggle
- Mobile dashboard redesigned: 2 pages with enriched compact cards + cashflow type
- Login UI simplified: remove gradient bg, subtitle, icon; use design tokens
- Focus OTP input when session is restored from 2FA state
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
- Remove green/red/blue coloring from summary totals on all report pages
(Facturi, Facturi pe Parteneri, Casă, Bancă) — mobile and desktop,
light and dark mode; totals now use --text-color like TrialBalance
- Fix SplitButton (Export) dark mode: was blue (--color-primary), now
matches secondary outlined style (--text-color / --surface-border)
- Update button syntax: severity="secondary" outlined instead of legacy
class="p-button-outlined p-button-secondary"
- DetailedInvoices: partner-meta (8 facturi) inline with partner name
via flex-direction row instead of column
- TrialBalance: mobile flat-row list layout replacing card layout
- Dashboard mobile title: shows company name + period instead of static "Dashboard"
- Navigation: move Facturi pe Parteneri to RAPOARTE section;
update MobileBottomNav default items (Detalii replaces Facturi)
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Replace hardcoded '/api/telegram' with import.meta.env.BASE_URL + 'api/telegram'
to match the reports API pattern. In production the base is '/roa2web/' so absolute
paths bypassed IIS sub-app routing, causing 404 on generate-code endpoint.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Replaces "luna prec / luna curentă" columns with a clearer accounting
reconciliation flow: Datorat (owed) → Achitat (paid) → Sold (remaining).
Backend models gain 3 new fields per sub-account and group. Frontend
shows ✓ when a debt is fully cleared. Mobile TVA card now shows both
total and remaining sold. SwipeableCards gains fixedDots/fillHeight props
for better layout above MobileBottomNav. Telegram formatter updated to
use new fields and drops redundant RON suffix from amounts.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Server switch flow now edits the original message at each step
(progress, error, company list) instead of sending separate messages.
"Server schimbat" notice is folded into the company selection header.
Also adds budget debt breakdown to dashboard formatter.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
- Add A-Z alphabetical filter keyboard for clients and suppliers lists
(same pattern as company selection, without emoji)
- Increase clients/suppliers list pagination from 10 to 20 items per page
- Remove emoji from company A-Z filter button for consistency
- Add 6 new callback handlers: clients_alpha_menu, clients_alpha:LETTER,
clients_alpha_page:PAGE:LETTER, and supplier equivalents
- Dashboard service and models updates
- Telegram bot: email handlers, auth, DB operations, internal API improvements
- Frontend: dashboard cards updates (CashFlow, Clienti, Furnizori, Treasury)
- Frontend: SolduriCompactCard and CollapsibleCard improvements
- DashboardView enhancements
- start.sh and run-with-restart.sh script updates
- IIS web.config and service worker updates
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
- Remove legacy pool support (DSN, env vars fallback)
- Use first registered server when server_id not specified
- Show server dropdown even with single server in ORACLE_SERVERS
- Email login only available for 2+ servers
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
- Add alembic.ini config for data_entry module
- Add migrations.py helper with:
- run_migrations(): runs pending migrations at startup (returns True/False)
- get_current_revision(): returns current schema version for /health
- Integrate migrations in main.py startup_event() BEFORE init_data_entry_db()
- Add data_entry_schema_version to /health endpoint
If migrations fail, backend continues with WARNING (not crash).
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Add UTF-8 encoding setup at the top of backend/main.py to fix
'charmap' codec encoding errors when logging Romanian diacritics
(ă, î, ș, ț) on Windows console.
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>