feat(app): implement Product Scan review flow, dynamic batch expiry picker, custom PDFs, PO relationships, and aligned card layouts
This commit is contained in:
1 parent
9ff4a4a922
commit
577be04308
69 files changed
+5645
-1657
No files matched your search
@@ -59,3 +59,26 @@ workflow and have no task numbers; see `git log` for real dates/history.
|
||||
## Backend — Postgres Data Layer
|
||||
|
||||
- **7.1** Wrapped the `ocr_items` delete-then-reinsert in `/api/parse` and `/api/v1/documents/[id]` PUT inside a DB transaction (`withTransaction` helper, `backend/pfm-web-app/src/db/index.ts`) — a mid-loop insert failure now rolls back to the previous item set instead of leaving a document with a correct header but partial/missing items — shipped 2026-07-08.
|
||||
|
||||
## Flutter — Document Editor & PDF Receipt
|
||||
|
||||
- **Ad-hoc (Product Scan flow)** — Shipped 2026-07-09
|
||||
- Implemented mock upload and response flow for Product Scanner review. Created a dedicated `ProductEditorScreen` with crop preview, AI classification confidence indicator, and dynamic drop-down SKU selector (Fiesta Spicy Chicken Nugget, Akumo Coin, Fiesta Schnitzel).
|
||||
- **Ad-hoc (Fuzzy Batch Expiry Selector)** — Shipped 2026-07-09
|
||||
- Built dynamic expiry date batch matching dropdown (Batch 1, Batch 2, manual input date picker) based on selected Master SKU product.
|
||||
- **Ad-hoc (Custom Product PDF)** — Shipped 2026-07-09
|
||||
- Redesigned the printed PDF receipt layout specifically for Product Scan (titles, headers, detail table parameters, store staff signatures) while preserving the same consistent professional layout styling as DO Scan receipt.
|
||||
- **Ad-hoc (PO Document Relationship)** — Shipped 2026-07-09
|
||||
- Added "Hubungkan ke PO Dokumen" dropdown to select and relate the Product Scan to a confirmed DO Scan document via PO Number (`noPo` relational field).
|
||||
|
||||
## Flutter — Pending Documents Queue / History
|
||||
|
||||
- **Ad-hoc (Custom Tab Switcher)** — Shipped 2026-07-09
|
||||
- Switched the documents history view to show two tabs (DO Scan and Product Scan) with DO Scan as default, removing the "All" tab.
|
||||
- **Ad-hoc (Document Card Alignment)** — Shipped 2026-07-09
|
||||
- Styled DO Scan and Product Scan history cards with matched structures:
|
||||
- Top category label: Staff Name for DO Scan (Orange), Product Name for Product Scan (Green).
|
||||
- Main Title: PO Number for DO Scan (directly without prefix), Batch Number for Product Scan (`[Batch Name]`).
|
||||
- Subtitle Details: `[Date] • [Item Count] Item` for DO cards, and `[Expiry Date] • [PO Number]` (without prefix labels) for Product cards.
|
||||
- **Ad-hoc (Active Account Seeding)** — Shipped 2026-07-09
|
||||
- Seeded 1 initial mock DO Scan document and 1 Product Scan document matching the currently logged-in account/store code if empty.
|
||||
Reference in new issue
Block a user