# Visit-shell completion — RESUME

**Status (2026-10-23):** all WPs implemented, committed on `hazemdev3` (NOT pushed, NOT merged to main — owner runs `/fullpush`), deployed to moonui3 `/app` (main-DEDSDMZY.js, I18N `20261023vsc4`). Fable FINAL verification (2026-10-24): **APPROVE WITH FIXES**, no P0 — NEW-1 fixed in BE e7b870d60; see `design/FABLE-review-FINAL.md` (P2s §4).

Source: prototype review `his-analysis/visit-shell-prototype-review.html` → owner «كمل كل الي ناقص … بتوصياتك … إضافة سهلة من مكانها … فابل يراجع كل حاجة».

## Commits
- **BE:** aacaac484 (wave BE: patient read, stay, flow state, catalog, vitals packs, layout settings, mirror, intake, nutrition products) · f008e9e47 ([FIN] folio fixes) · 9fae23849 (hidden labels, restore clash, mirror freshness) · 674c1e134 (is_insured) · 007409760 (GYN complaints) · d3070f8df (GYN pack rerun) · c5ed456c9 (lab mode without LIS, pregnancy_open).
- **FE:** 10d02f96 (shell bugs) · 5fc82df9 (vitals packs) · 6a79cf67 (nutrition 15 cards) · 0931e8cb (picker everywhere) · 1f7ffdbe (chrome rest) · 24293645 (hidden labels) · 279b10c3 (in-place settings) · 887145ee (Fable fixes) + I18N bumps.

## What the owner gets (by area)
- **Settings in place:** «✎ تخصيص الشاشة» → per-card ⚙ (ظاهر/إلزامي/Select⟷Text/🔒/source), header ⚙, «إعدادات التخصص» sheet (GYN 6 groups, dental 8, shell switch, doctor override, facility type), scope «للعيادة كلها | لي أنا», layer colouring. Layout saves for all 4 types.
- **Picker:** catalog values added/renamed/hidden/reordered/moved/deleted from inside the picker («✎ إدارة», undo). Diagnosis/lab/rad/history on the picker with ★. General complaints + exam regions seeded. GYN complaints in Arabic, first on GYN visits.
- **Shell:** insurance name, lab flags, Rh-negative alert, notes flushed before sign, insured diagnosis forced (is_insured now sent), server flow state, summaries for every card, phone bill sheet, 44px touch, sign+print menu, inline follow-up + booking, results/meds/photos/intake cards, first-visit intake (outpatient).
- **Vitals:** specialty + inpatient packs in one card, compact grid, one inpatient round form («تسجيل الجولة»).
- **Nutrition:** board = 15 cards (classic pixel-identical), products sold.
- **Inpatient:** stay chip (ward·bed·day N/expected + attending), «حساب الإقامة», and **[FIN] lab/rad/service orders on admissions now go to the stay folio** (`clinic:repair-admission-orders`, dev: 7 empty strays cancelled).
- **Data:** `history_answer_values` link-row mirror (+ nightly command), nutrition intake goal fields, dental intake dedupe.

## Decisions taken (owner said «بتوصياتك») — see LEDGER «Decisions» + log
Insured → diagnosis forced (every type); doctors add+manage catalog values, nurse add; one facility-type selector over the 4 modes; GYN multi-select JSON stays + mirror; GYN private summary opt-in kept; settings in place (no Program-Setting screen); lab mode = standalone when the LIS module is disabled; inpatient vitals recorded as one round.

## Not verified (owner should click through)
No real writes were made by the agents on dev visits: saving a layout/rules (client + doctor), the specialty sheet saves (GYN features, dental write-through, facility type), catalog manage actions, recording a round, follow-up save/booking, sign + print menu, an insured visit end to end (dev has no insured patient). No full test suite was run (targeted files only — see LEDGER).

## Known leftovers / notes
- `visit-shell.component.ts` ~1300 lines → refactor candidate (print/booking/intake helpers into a service).
- rad has no «previous results» strip (rad.prev not offered); rx.interact = per-drug alert notes (no interaction engine).
- Restore clash shows a generic error in the picker undo (BE returns 422 on value_ar).
- Settings screen may still display `clinic.lab_mode = integrated` on installs without LIS (behaviour is standalone).
- Typed but unrecorded inpatient round is lost on leaving (hint only).
