{
  "@context": {
    "ixo": "https://w3id.org/ixo/ns/protocol/",
    "@id": "@type",
    "type": "@type",
    "@protected": true
  },
  "type": "ixo:entity#surveyTemplate",
  "question": {
    "title": "Stock Item Configuration Form",
    "description": "Define stock item attributes including type, collection availability, and country coverage.",
    "pages": [
      {
        "name": "stock_item_details",
        "elements": [
          {
            "type": "panel",
            "name": "item_basic_info_panel",
            "elements": [
              {
                "type": "text",
                "name": "schema:name",
                "title": "Item Name",
                "description": "Enter the name of the stock item",
                "isRequired": true
              },
              {
                "type": "dropdown",
                "name": "schema:type",
                "title": "Item Type",
                "description": "Select the category of the stock item",
                "isRequired": true,
                "choices": [
                  "Pellets",
                  "Accessory"
                ]
              },
              {
                "type": "text",
                "name": "ecs:bag_size",
                "visibleIf": "{schema:type} = 'Pellets'",
                "title": "Bag Size",
                "description": "Select pellet bag size",
                "isRequired": true,
                "inputType": "number"
              }
            ],
            "title": "Basic Item Information"
          },
          {
            "type": "panel",
            "name": "accessory_details_panel",
            "elements": [
              {
                "type": "dropdown",
                "name": "ecs:model",
                "title": "Model",
                "isRequired": true,
                "choices": [
                  "Mimimoto",
                  "Supamoto"
                ]
              },
              {
                "type": "dropdown",
                "name": "ecs:version_type",
                "title": "Version Type",
                "isRequired": true,
                "choices": [
                  "2nd Generation",
                  "3rd Generation"
                ]
              },
              {
                "type": "dropdown",
                "name": "ecs:size",
                "title": "Size",
                "isRequired": true,
                "choices": [
                  "Small",
                  "Normal",
                  "Large"
                ]
              },
              {
                "type": "dropdown",
                "name": "ecs:condition",
                "title": "Condition",
                "isRequired": true,
                "choices": [
                  "New",
                  "Preowned"
                ]
              }
            ],
            "visibleIf": "{schema:type} = 'Accessory'",
            "title": "Accessory Details"
          },
          {
            "type": "panel",
            "name": "availability_panel",
            "elements": [
              {
                "type": "checkbox",
                "name": "ecs:collection_type",
                "title": "Available for Collection Type",
                "description": "Select all applicable collection channels",
                "isRequired": true,
                "choices": [
                  "Depot",
                  "Supa Partner",
                  "Warehouse",
                  "Reseller",
                  "Mobile"
                ]
              },
              {
                "type": "checkbox",
                "name": "ecs:available_countries",
                "title": "Available for Countries",
                "description": "Select countries where this item is available",
                "isRequired": true,
                "choices": [
                  "Zambia",
                  "Malawi",
                  "Mozambique"
                ]
              }
            ],
            "title": "Availability Settings"
          }
        ]
      }
    ],
    "completeText": "Save Stock Item"
  }
}