Prerequisites
- The enum must be defined in Polarion (either a built-in enum like
severityor a custom enum) - The property must be included in your domain model
- Access to the sheet configuration and domain model YAML files
Step 1: Add the Enum Property to the Domain Model
Include the enum property in your entity type’sproperties section. Powersheet automatically detects enum types from Polarion metadata:
- Detects the enumeration ID from Polarion metadata
- Creates a data source for loading enum options
- Renders a dropdown picker in the sheet cell
Step 2: Understand Enum Option Scoping
Enum options in Polarion can vary depending on the context. Powersheet uses a scoping strategy to determine which options to display:| Scope Factor | Description |
|---|---|
enumId | The Polarion enumeration identifier |
project | The current Polarion project |
polarionType | The work item type (e.g., user_need) |
proto | The Polarion object prototype |
severity enum for UserNeed in project RTM_Demo resolves differently than severity for SystemRequirement in the same project.
Step 3: Restrict Enum Values (Optional)
To limit the available options to a subset, use theenumValues property in the domain model:
enumValues must match Polarion enum option IDs exactly.
Step 4: Set Default Values (Optional)
Powersheet automatically infers default values for enum properties from Polarion enumeration definitions. The resolution order is:- Explicit default in the domain model property definition
- Polarion enumeration default from the enum configuration
- No default (
null)
The default value inference depends on Polarion’s enum configuration. Verify the default behavior in the application if you need a specific initial value.
Step 5: Add the Column to Sheet Configuration
Reference the enum property in your sheet configuration:Step 6: Assign the Sheet Configuration to a Document
Ensure your document references the correct sheet configuration via thenextedySheetConfig custom field. See Assign Configuration to Document for details.
Step 7: Verify
Open the powersheet document. Click on a cell in the enum column. You should now see a dropdown with the expected options. Select a value, save, and confirm it persists.See Also
- Create a Custom Field — add custom fields to the domain model
- Add a Custom Property — detailed property configuration
- Configure Picker Filters — filter entity pickers with constraints
- Configure a Formatter — apply conditional styling to enum values
Sources
Sources
KB Articles
- Getting Started: Sheet Configurations
- Install POWERSHEET into an Existing Project
- How to Migrate from Legacy to New Powersheet Configuration
prod-powersheet-src/com.nextedy.powersheet.client/ltc-repo/packages/common/types/api/document.tsprod-powersheet-src/com.nextedy.powersheet/src/com/nextedy/powersheet/enumProvider/SheetConfigEnumProvider.javaDataPropertyFactory.javaprod-powersheet-src/com.nextedy.powersheet/src/META-INF/hivemodule.xmlPolarionQueryProcessor.java