Feature Request: BOE-Level Variables Scoped to a Single BOE
Summary:
Enable users to define BOE-level variables that are created within and specific to a single BOE. These variables should function similarly to existing proposal-level variables but be scoped so they only apply within the selected BOE, providing more granular control and reducing cross-BOE coupling.
Problem Statement:
Currently, users rely on proposal-level variables even when a value is only relevant to a single BOE. This forces either duplication of logic or reuse of broadly scoped variables for narrow, BOE-specific needs. As a result, managing changes becomes error-prone: updating a proposal-level variable to support one BOE can unintentionally impact others, while creating separate structures to work around this limitation increases complexity, maintenance effort, and the risk of misconfiguration.
Proposed Solution:
Introduce BOE-level variables that can be created, edited, and used within the context of a single BOE.
Provide a dedicated UI in the BOE configuration or setup area to define and manage these variables (name, type, description, default value, and allowed value constraints where applicable).
Ensure BOE-level variables are available for use in BOE calculations, formulas, and fields in the same way proposal-level variables are, but only within that BOE.
Visually distinguish BOE-level variables from proposal-level variables wherever variables are referenced or selected (e.g., grouping, labeling, or icons).
Prevent BOE-level variables from being referenced outside their owning BOE, with clear validation messages if a user attempts to reuse them globally.
Support cloning/duplication behavior: when a BOE is copied, provide clear behavior for whether its BOE-level variables are copied with it, including values and references.
Benefits:
Reduces the risk of unintended side effects by limiting variable scope to a single BOE.
Simplifies configuration and maintenance for BOEs with unique assumptions or parameters.
Improves clarity for users selecting variables, making it easier to distinguish global (proposal-level) values from local (BOE-level) ones.
Supports more flexible modeling of complex proposals where individual BOEs require different drivers or assumptions.
Enhances overall data integrity and user confidence by making variable scope explicit and controlled.