GUBUS MULTIPANEL

Multipanel is GUBUS's primary INPUT pattern for collecting data from users through Google Sheets.

Multipanel utilized the huge functionality of Google Spreadsheets and could be powered and automated with formulas and data validations, that crafts unbelievable flexibility and functionality in a minutes!

Multipanel can also be represented as Telegram Bot flow. Check it out here…

💡

Multipanel is your go-to pattern for simple row-based data input.

When to use Multipanel:

  • Collecting daily inputs (tasks, orders, supply events)
  • Form-like data entry with multiple rows
  • Temporary staging area for data before processing
  • Input workflows that need validation and auto-cleanup

How Multipanel Works

In READ Stage

How GUBUS reads Multipanel:

[GUBUS SCHEMA READ STAGE]
  → [Read multipanel]
  → [Validate] if configured, strongly recommended, remember about layered validation
  → [Compose message] if configured, strongly recommended
  → [persist to SchemaContext.localObjs]
  → [Pass to Transform stage]

Step-by-step:

  1. Schema calls readMultipanelForSchemaContext()
  2. Data extraction starts at row panel_line_zero_based
  3. Reading stops when:
    • stop_read_field is empty (most common)
    • stop_read_field equals stop_read_value
    • max_lines limit is reached
  4. Built-in validation executes if configured via validate transform with reference matching multipanel reference
  5. Validation failures are exposed using front_to_pivot_model (user-friendly field names)
  6. Data is mapped from array to object format using model field
  7. Results stored in schemaContext.localObjs
  8. Built-in composer creates summary message using header/footer/pattern
  9. Optional cleanup: Panel is cleaned if clean flag is set to “on”. Not recommended on test stage, mandatory on production run.
💡

The most common read configuration is stop_read_field pointing to the main mandatory field in your panel (like “task_name” or “order_no”). This ensures reading stops when users leave the next row empty.


In POST Stage

When a schema writes to a Multipanel:

[Transform Result]
  → [SchemaContext.localObjs]
  → [Map to panel coordinates]
  → [Update multipanel row by row]

Step-by-step:

  1. Schema calls executeMultipanelGubusPatternPostPending()
  2. Each object in schemaContext.localObjs is converted to sheet row
  3. Rows are updated without insertion starting at panel_line_zero_based + offset
  4. Validation check: If rows to insert exceed max_lines, SchemaContext is falsified and execution stops as a whole
  5. Data is mapped using model field
💡

POST to Multipanel is always treated as a “set back” operation - it’s meant for correcting or returning data to the input panel, not for new data entry.


Key Mechanics

Panel Positioning:

  • Uses panel_line_zero_based to determine starting row (0-indexed, so 5 means row 6 in Google Sheets)
  • All read and write operations start from this line

Line Limits:

  • max_lines enforces maximum rows to prevent overflow
  • If exceeded during POST, execution stops immediately

Stop Conditions:

  • Cell under stop_read_field is empty
  • Alternative: stop_read_field equals stop_read_value
  • ‘max_lines’ condition reached

Built-in Validation:

  • Configured via validate transform with reference matching multipanel
  • Validation errors are exposed with user-friendly field names from front_to_pivot_model
  • Failed validation prevents further processing

Built-in Composer:

  • Creates summary messages using header, footer, and message_construct_pattern
  • Message includes data from message_construct_fields
  • Useful for bot notifications and team communication

Auto-Cleanup:

  • Panel can be automatically cleaned after successful read
  • Set clean to “on” for idempotent workflows
  • Set are_checkboxes for checkbox fields to switch them off during clean
  • Ensures panel is ready for next input session

Key Properties

Location Properties (Required)

PROPERTY
DESCRIPTION
table_id
Google Spreadsheet ID (auto-detected on DETECT PATTERN flow)
sheet_id
Sheet GID (auto-detected on DETECT PATTERN flow)
sheet_name
Sheet tab name (auto-detected on DETECT PATTERN flow)
reference
Unique identifier that describes multipanel purpose
model
Maps array to object (auto-created: {order_no: 1, customer: 2})
front_to_pivot_model
User-friendly field names (auto-created: {order_no: “Order #”})

Read Configuration

PROPERTY
DESCRIPTION
panel_line_zero_based
Starting row for data (0-indexed). Example: 5 means row 6 in Google Sheets
max_lines
Maximum rows to read or write. Example: 20
stop_read_field
Field to check for stop condition. Example: “task_name”
stop_read_value
Value that stops reading. Usually empty for “read until empty”
💡

Always set stop_read_field to your crucial essential field. This ensures reading stops at the first empty cell.


Data Mapping (Critical)

Data mapping is automatically generated by GUBUS on pattern creation flow, triggered either from AI interacton or from ‘admin_server’ sheet.

PROPERTY
DESCRIPTION
model
Maps column positions (1-indexed) to object field names. Example: {order_no: 1, customer: 2, total: 3}
front_to_pivot_model
Provides user-friendly labels for validation error messages. Example: {order_no: “Order #”, customer: “Customer Name”}

Behavior Flags

PROPERTY
DESCRIPTION
clean
Auto-clean panel after read. Set to “on” for idempotent workflows
mute_on_set_back
Fields not overwritten on POST (comma-separated field names)
mute_on_clean_labels
Suppress clean notifications to reduce noise
provide_validation
Enable built-in validation (always set to true)
are_checkboxes
Checkbox fields to switch off during clean (comma-separated field names)
💡

Always enable provide_validation and configure validation rules. Validation catches errors before processing.


Message Construction

PROPERTY
DESCRIPTION
header
Message header template
footer
Message footer template
message_construct_pattern
Pattern with placeholders. Example: “Order {order_no} from {customer}“
message_construct_fields
Fields to include. Example: “order_no,customer,total”
composer
Reference to composer configuration

The composer creates summary messages after reading panel data. This is useful for bot notifications and team visibility.


Common Use Cases

Use Case 1: Supply Accounting

Scenario: Employee inputs multiple supply events throughout the day.

Schema Flow:

READ multipanel
  → VALIDATE supplies
  → POST to storage workfeed
  → POST to finance workfeed

Why Multipanel? Structured multi-row input with validation and auto-cleanup ensures panel is ready for next shift.


Use Case 2: Order Payment

Scenario: Single order payment input with bot integration.

Schema Flow:

READ orderInputPanel (or bot input)
  → CALCULATE totals
  → CALL Workflow module
  → UPDATE item state
  → POST to transactions

Why Multipanel? Simple structured input with immediate validation and workflow integration.


Schema Integration

READ Configuration

In GUBUS SCHEMA rule:

Properties to set:

  • source_type: Choose “MULTIPANEL”
  • source_reference: Panel reference (e.g., “orderInputPanel”)
    • ⚠️ Does NOT support multiple references (one panel per schema), to read from multiple panels, use separate inner schemas

POST Configuration

In GUBUS SCHEMA rule:

Properties to set:

  • target_type: Choose “MULTIPANEL”
  • target_names: Panel reference (e.g., “orderInputPanel”)
    • ⚠️ Does NOT support multiple references (one panel per schema)
💡

Remember: POST to multipanel = “set back” operation for data correction.


Complete Flow Examples

Example 1: Order Processing Pipeline

Schema: processOrders
├─ READ stage
│  ├─ source_type: MULTIPANEL
│  └─ source_reference: orderInputPanel
│     └─ Reads new orders from panel (lines 5-25)

├─ TRANSFORM stage
│  ├─ validate (built-in multipanel validation)
│  ├─ calculateTotals
│  └─ enrichWithCustomerData via join module

└─ POST stage
   ├─ target_type: WORKFEED
   └─ target_names: orderHistoryFeed
      └─ Appends to permanent order log

Example 2: Round-Trip (Panel → Feed → Panel)

Schema: processTasks
├─ READ stage
│  ├─ source_type: MULTIPANEL
│  └─ source_reference: taskInputPanel

├─ TRANSFORM stage
│  └─ validateAndEnrich

└─ POST stage
   ├─ target_type: WORKFEED
   └─ target_names: taskHistoryFeed

---

Schema: prepareReport
├─ READ stage
│  ├─ source_type: WORKFEED
│  └─ source_reference: taskHistoryFeed

├─ TRANSFORM stage
│  └─ summarize, format

└─ POST stage
   ├─ target_type: MULTIPANEL
   └─ target_names: taskReportPanel (set back operation)

Best Practices

Do’s ✅

General:

  • ✅ Use meaningful reference names (camelCase, descriptive like “dailyTaskInput”)
  • ✅ Always configure validate - validation catches errors and aborts execution, preventing false executions and postings
  • ✅ If needed configure built-in composer expose important executions to teams
  • ✅ Enable clean flag only after TEST stage to prevent accidental data deletion

Configuration:

  • ✅ Reset stop_read_field to crucial field, on pattern creation GUBUS sets first field randomly to it
  • ✅ Use mute_on_set_back to protect certain fields during corrections
  • ✅ Configure are_checkboxes explicitly for all checkbox columns

Troubleshooting

”Pattern not found for client X and schema Y”

Cause: Misspelled pattern reference in GUBUS SCHEMA configuration.

Solution: Go back to schema and use Data Validation to select pattern reference - this ensures you choose only valid references.


”Lines to insert exceed max_lines allowed”

Cause: Trying to write more rows than max_lines permits.

Solution:

  • Increase max_lines in multipanel configuration
  • Filter data in TRANSFORM stage to reduce rows
  • Consider using multiple panels or pagination

Validation Errors

Possible causes:

  • panel_line_zero_based misconfigured
  • Pattern moved left/right in sheet (breaks model mapping)
  • model mapping doesn’t match actual columns
  • stop_read_field not configured (reads too much)
  • Sheet has no data in expected range
  • User entered false values or not entered any

Solution checklist:

  • ✓ Verify panel_line_zero_based points to correct starting row
  • ✓ Check model mapping matches current sheet structure
  • ✓ Confirm stop_read_field is set to main mandatory field
  • ✓ Verify sheet has data in expected range
  • ✓ Check you haven’t moved pattern horizontally

Clean Not Working (In users terms: Data Doesn’t Disappear)

Cause: Flag not set correctly or running in debug mode.

Solution:

  • Check clean is exactly “on” (string value)
  • Verify schema is not running in debugContext (clean disabled in debug mode)
  • Confirm schema execution was successful (clean only happens on success)

Creating a New Multipanel

  1. Shape pattern header manually in your Google Sheet

    • Add user-friendly field names in header row
    • Use your users’ language
  2. Go to admin_server page in ‘admin’ table

    • Find inject_pattern panel
  3. Run detection flow:

    • Choose pattern type: “multipanel”
    • Enter unique reference name (descriptive, camelCase)
    • Assign table_id and sheet_name
    • Click DETECT PATTERN button
    • GUBUS auto-detects sheet_id
  4. Map fields:

    • GUBUS posts field name options over header
    • Choose from suggested names or enter custom ones
    • Click MAP FLOW button
    • GUBUS creates model and front_to_pivot_model automatically
  5. Configure behavior:

    • Reset max_lines (GUBUS sets it to 1 by default)
    • Configure stop_read_field and stop_read_value
    • Set clean behavior (“on” or “off”)
    • Set mute_on_set_back if needed
    • Set mute_on_clean to suppress notifications
    • Configure are_checkboxes for checkbox columns
    • Enable provide_validation
  6. Test:

    • Test with small dataset first
    • Verify data flows correctly through READ and POST stages
    • Enable clean="on" only after successful testing

Option 2: AI flow (Experimental)

Talk to GUBUS AI on developer page, it will execute everything needed for you!

Required properties:

  • your understanding of what and what for you want to instantiate

FAQ

WHEN SHOULD I USE MULTIPANEL VS WORKFEED? +

Use Multipanel for temporary data entry that gets cleared after processing (orders, daily tasks, forms). Use Workfeed for permanent historical records that need to be preserved (transaction logs, audit trails, archives).

CAN I READ FROM MULTIPLE MULTIPANELS IN ONE SCHEMA? +

No, each schema can only read from one multipanel. To read from multiple panels, create separate inner schemas for each panel and chain them together using next_schema or batch execution.

WHAT HAPPENS IF VALIDATION FAILS? +

When validation fails, GUBUS stops execution immediately and exposes user-friendly error messages using front_to_pivot_model field names. The panel is NOT cleaned, preserving the user’s data for correction.

HOW DOES AUTO-CLEAN WORK WITH CHECKBOXES? +

Configure are_checkboxes with comma-separated field names (e.g., “is_urgent,is_paid”). During clean operation, these fields are switched OFF instead of being cleared, maintaining proper checkbox state in Google Sheets.

CAN I INTEGRATE MULTIPANEL WITH TELEGRAM BOTS? +

Yes! To expose multipanel via Telegram/Viber bot: (1) Involve workfeed reference to enable bot exposure, (2) Configure main_bot_menu rule to access multipanel exposure via button in telegram menu, (3) Configure bot_steps rule to set up interaction sequence.


Summary

Multipanel is GUBUS’s ephemeral input pattern designed for:

  • ✅ Temporary data collection
  • ✅ Form-like multi-row input
  • ✅ Automatic validation and cleanup
  • ✅ Built-in message composition

Key characteristics:

  • Reads from fixed panel area (panel_line_zero_based)
  • Enforces row limits (max_lines)
  • Stops at empty field (stop_read_field)
  • Auto-cleans after processing (clean="on")
  • Validates with user-friendly errors (validate + front_to_pivot_model)

When to use:

  • Daily input tasks
  • Order/transaction entry
  • Survey collection
  • Any temporary staging data

When NOT to use:

  • Historical data storage (use Workfeed)
  • Append-only logs (use Workfeed)
  • Data that needs persistence (use Workfeed)

For permanent data storage and historical records, use Workfeed Pattern instead.


Next Steps

👉 Back to GUBUS RULE → - Learn about GUBUS rule structure 👉 Continue to GUBUS SCHEMA → - Learn how schemas execute data workflows 👉 ← Back to Getting Started - Return to the main documentation