Product EngineeringFeaturesLab FormsFrontendcrelio-app

AOE Forms & Submission

AOE form reuse, value submission, and submission payload preparation in the patient UI.

👤 Ritu Kataria📅 Updated: Mar 13, 2026🏷️ feature

AOE Forms & Submission


10.6 AOE Forms Reuse

The AOE (Ask at Order Entry) forms in the CRM section reuse the same rendering pipeline as Consent forms, without duplicating any rendering logic.

How AOE reuses the consent renderer:

  • AOEFormSectionComponent calls calculateFormConfig() from the ConsentForm utilities
  • Same JsonToForm component with ConsentSectionTitle renderer
  • AOE config is fetched via a separate API and stored in the AOEConfiguration Redux type
  • Process types differ: AOE uses Test, Profile, Promotion, Store, Bill process types (vs Consent's Patient, Start Up, Sample, Close Down)
  • Field values are tracked in common.questionValues keyed by process_id → question_id
  • AOE sections are dynamically injected into the multi-section form's section order via prepareSectionOrder()

10.7 Submission

Payload Structure

Built by prepareConsentValues() in ConsentForm/utils.ts:

{
  "bill_id": 123,
  "lab_form_id": 456,
  "home_collection_id": null,
  "lab_id": 789,
  "values": [
    {
      "value": "answer text",
      "process_id": 1,
      "question_id": 2,
      "report_id": null,
      "iteration": 1
    }
  ]
}

Value Serialization (prepareValue())

Value TypeSerialization
ArrayJoined with ", "
Date / DateTime / TimeFormatted with moment using the field's dateformat/timeFormat
Boolean"true" / "false"
Upload (files)JSON.stringify(value) — the { fileName: s3Key } map
Signaturevalue.bucketPath — the S3 key only
OtherRaw string value

Submission Endpoint

POST /api-v3/account/consent/questions/values/bulk/guest

This endpoint is CSRF-exempt and unauthenticated, allowing patients to submit from the public patient portal URL without a session.

On this page