[
    {
        "name": "product_id",
        "label": "Product",
        "type": "select-search",
        "required": true,
        "options_table": "products",
        "options_label_column": "name",
        "options_value_column": "product_id",
        "help_text": "Select the product to break down into smaller units"
    },
    {
        "name": "branch_id",
        "label": "Warehouse/Branch",
        "type": "select",
        "required": true,
        "options_table": "branches",
        "options_label_column": "name",
        "options_value_column": "branch_id"
    },
    {
        "name": "from_unit",
        "label": "From Unit (Bulk)",
        "type": "select",
        "required": true,
        "options": [
            {"value": "CARTON", "label": "Carton", "display_text": "Carton"},
            {"value": "BOX", "label": "Box", "display_text": "Box"},
            {"value": "PACK", "label": "Pack", "display_text": "Pack"},
            {"value": "MASTER", "label": "Master Unit", "display_text": "Master Unit"}
        ],
        "help_text": "The larger unit you are breaking down"
    },
    {
        "name": "to_unit",
        "label": "To Unit (Individual)",
        "type": "select",
        "required": true,
        "options": [
            {"value": "PIECE", "label": "Piece", "display_text": "Piece"},
            {"value": "PACK", "label": "Pack", "display_text": "Pack"},
            {"value": "UNIT", "label": "Base Unit", "display_text": "Base Unit"}
        ],
        "help_text": "The smaller unit you are creating"
    },
    {
        "name": "quantity",
        "label": "Quantity to Break",
        "type": "number",
        "required": true,
        "min": 0.01,
        "help_text": "How many bulk units to break down"
    },
    {
        "name": "batch_number",
        "label": "Batch Number",
        "type": "text",
        "required": false
    },
    {
        "name": "notes",
        "label": "Notes",
        "type": "textarea",
        "required": false,
        "colspan": 2
    }
]