BioFlow API - rounds oct40 + oct41 together (migrations 115, 116, 117)

What changed
- Maintenance / complaints: the patient's complained machine is locked on the order. Completing asks what was done:
  Repaired (same machine stays), Replaced (pick the new unit given; the complained one comes back Under maintenance),
  or Standby (loan unit). A QR scan on site only checks it is the patient's machine.
- Rent collection visits show "Collected Rs X for <rental>" in histories and lists. Recording again through a visit that
  already has a collection asks first; a completed visit refuses (record on the rental itself).
- Consumable size printed on the work order, tax invoice, proforma, credit note and delivery challan.
- Tax invoice numbers are now per FINANCIAL YEAR (April-March): TBF/26-27/00001. Credit notes CN/26-27/00001.
- Accounts: Invoices module, freeze a period, GST export (GSTR-1 sheets), Sales-on-tax-invoice switch in Masters.
- oct41 Service board: the Service module is a board of stages (Needs service, To assign, With engineer, To send,
  On the way, At vendor / branch, Coming back, Check & confirm, Back in stock). Sending a unit out can ask for photo /
  video proof; the dispatcher enters courier name, tracking ID and courier charge; the destination branch's people
  get a "Courier to collect" task and alert; the service head sets the vendor's ready date (a follow-up reminder) and
  confirms the unit back to stock.
- oct41 Courier moves board for branch, consumable and inter-company moves; every dispatch can carry a courier charge
  (paid by me = an expense claim under "Courier"), receiving needs a photo.
- oct41 Sell this machine: another machine of the same type only (model filter, serial search with branch); one
  "Pending rental" field - collected part recorded as rent, the rest written off (super / Accounts at once, others
  send it for approval). The sale bill is the machine price only.
- Smoke test: --quick (about 2 minutes) and --sections=; the full run is still the default.

Deploy (today, before 1 November billing starts)
1. Extract this zip in public_html/
2. cd medserv-api && php bin/migrate.php                        (115, 116, 117)
3. php bin/smoke_test.php                                       (full run this time - expect 0 failed)
4. php bin/invoice_golive.php --company=TBS --start=2026-11-01  (dry run - read the list)
   php bin/invoice_golive.php --company=TBS --start=2026-11-01 --confirm
   Every TBS tax invoice dated before 1-11 becomes PRE-<old number> (its PDF says the GST invoice came from Tally);
   the first invoice from 1-11 is TBF/26-27/00001. KBS / GRANT: run the same only if they want it.
5. FRANSCISCA (TBS-2026-10/30/030) - first look at both units:
   php bin/machine_trace.php X2306170584      and      php bin/machine_trace.php ID2025020370
   then the repair (dry run, then add --confirm):
   php bin/fix_swapped_replacement.php --company=TBS --order=TBS-2026-10/30/030 --with-patient=ID2025020370 --taken-back=X2306170584
   If the dry run names a third unit as the order's standby, tell Claude before confirming.

Next time: php bin/smoke_test.php --quick for routine deploys; the full run when the notes say so.
