diff --git a/scripts/document_gen/templates/mcs150_pdf_filler.py b/scripts/document_gen/templates/mcs150_pdf_filler.py index c81c3f8..3725838 100644 --- a/scripts/document_gen/templates/mcs150_pdf_filler.py +++ b/scripts/document_gen/templates/mcs150_pdf_filler.py @@ -261,9 +261,17 @@ def fill_mcs150(intake: dict, order_number: str = "") -> str: if cargo in CARGO_TYPE_MAP: checkbox_on[CARGO_TYPE_MAP[cargo]] = True - # The bottom certification ("I ... certify ...") box is always checked -- - # the client signs the perjury certification. - checkbox_on["certifyBox"] = True + # Q29 Passenger Carrier Compliance Certification "YES" box. Only motor + # passenger carriers certify here -- leave it unchecked for freight/property + # carriers. (The Q31 perjury declaration is made via the signature, not a + # checkbox.) + is_passenger = ( + intake.get("is_passenger_carrier") == "yes" + or carrier_op in ("private_passengers_business", "private_passengers_non_business", + "private_passengers") + ) + if is_passenger: + checkbox_on["certifyBox"] = True # ── Radio-button groups (value /0../4, not /Yes) ───────────────── # These are single-select radio fields; the selected option index is the