@davoodmehraban89 / Factor-easy-2 Mirror · read-only / commits / 6e06081
Fork 0

سامانه صدور فاکتور و حسابداری

Mirrored from https://github.com/davoodmehraban89/Factor-easy.git

Synced Dec 3, 22:00 UTC

docs(stage3.2): scope guarded sale invoice server posting without production cutover

davoodmehraban89 committed Oct 23, 2026 at 03:18 UTC 6e06081318d34a6a1a10b6913bafc424c70f9a88
1 file changed +6
PROJECT_STATE.md
+6
@@ -254,3 +254,9 @@
254 - Other four disposable Supabase CI jobs: actual built Pages local JWT/manual real-stack, strict 1069-object/154-function snapshot parity, synthetic Stage1 rollback preserving data/version, and manual journal harness/3-path client contract all SUCCESS.
255 - Quality Run 39872797038 COMPLETED SUCCESS exact same SHA: 124/124 browser Playwright including actual new sale and purchase source fields, plus all three independent database jobs. Security Run 39872797133 COMPLETED SUCCESS CodeQL and release-safety; Dependency Review SKIPPED, GitHub repository Dependency Graph remains disabled.
256 - **No production finance integration completed or released:** the running UI still uses legacy jePostSourceRecord; an independent isolated test calling server RPC is evidence of server contract feasibility, not a client cutover. Needs a guarded async source sync/POST adapter preserving server-owned fields, CAS, tenant isolation, no blind retries, and per-source actual browser end-to-end before merge. Real tenant owner mappings and backups/restore, non-IRR pricing, quantity rounding and COGS remain separate unapproved gates. No Production SQL/data, main merge, paid cloud or deployment.
257 +
258 +### 2026-10-23 — Stage3.2 guarded sale invoice cutover design, experimental feature branch
259 +- Owner requires sequential real work without premature completion; zero cost and no Production write/merge/deploy continue. Stage2 SQL is absent from Production; this code MUST remain DRAFT QA-only.
260 +- Prior Stage3 source contract PR #165: real browser 124/124 and UI->SQL-v1 2/2 + 12 negatives; subsequent QA #166: synthetic original Chromium sale/purchase source posted through real disposable Auth/JWT/PostgREST 2 times, replayed twice, 3 forged attempts denied, all server-owned lines. Test evidence exact SHA 75589852450bf2dc1652998c37e5c2e32354db2b. PR166/165/162 remain draft.
261 +- New Stage3.2 isolated branch feature/finora-stage3-enforce-invoice-rpc-20261023 from PR166 QA before any main merge. Next approved scope ONLY existing new *sale invoice* finalize under server guard=enforce: preserve draft source, targeted CAS sync of this source only, server RPC `finora_journal_autopost` (no browser lines/numbers), targeted voucher reload, derive posted state from journal source linkage without mutating original source. Server rejects non-IRR/unsupported contracts. Legacy off/audit behavior remains untouched. Fail closed on timeout/conflicts; never blind pullAll.
262 +- Must add behavioral RED first to existing Playwright fixture and then GREEN, with exact-head Quality full suite, Security, 5-job disposable real-stack regression; real Production owner account-role signoff, conversion policy, backup and hosted external staging are separate gates. Do not call Stage3 accepted or ship UI until all required checks and permissions.