{
  "@context": {
    "ixo": "https://w3id.org/ixo/ns/protocol/",
    "@id": "@type",
    "type": "@type",
    "@protected": true
  },
  "type": "ixo:entity#surveyTemplate",
  "question": {
    "title": "Customer Payment Claim",
    "description": "Record a payment made during customer onboarding. A red star * means you must answer.",
    "pages": [
      {
        "name": "payment_claim",
        "elements": [
          {
            "type": "text",
            "name": "ecs:customerId",
            "title": "SupaMoto customer ID",
            "isRequired": true
          },
          {
            "type": "dropdown",
            "name": "schema:purpose",
            "title": "Reason",
            "isRequired": true,
            "choices": [
              "Onboarding fee",
              "Application fee",
              "Fuel purchase"
            ]
          },
          {
            "type": "paneldynamic",
            "name": "ecs:fuelSpecification",
            "visibleIf": "{schema:purpose} = 'Fuel purchase'",
            "title": "Fuel Information",
            "templateElements": [
              {
                "type": "text",
                "name": "ecs:batchID",
                "title": "Batch ID",
                "isRequired": true
              },
              {
                "type": "text",
                "name": "schema:quantity_bags",
                "title": "Number of bags",
                "isRequired": true
              },
              {
                "type": "dropdown",
                "name": "schema:quantity",
                "title": "Weight of bags",
                "isRequired": true,
                "choices": [
                  "1kg",
                  "5kg",
                  "30kg",
                  "50kg"
                ],
                "showOtherItem": true
              }
            ]
          }
        ],
        "title": "Customer payment"
      }
    ],
    "questionErrorLocation": "bottom",
    "completeText": "Submit payment claim",
    "showPreviewBeforeComplete": true
  }
}