octobercms/october · error · SystemException
Treeview branch grouping is only supported for the LIST…
Error message
Treeview branch grouping is only supported for the LIST display mode
What it means
State-conflict validation in NodeDefinition::setDisplayMode: grouping (setGroupBy) was previously configured, but display mode is being set to a non-LIST mode. Branch grouping is only rendered by the flat list presentation, so combining groupBy with tree mode is rejected.
Solutions
- Keep DISPLAY_MODE_LIST when using setGroupBy
- Call setGroupBy(null)/remove grouping before switching to tree display mode
Defensive patterns
Strategy: validation
When it happens
Trigger: Thrown at modules/backend/vuecomponents/treeview/NodeDefinition.php:145 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of octobercms/october@b608633a7e (2026-08-21).
Data as JSON: /api/errors/e4f7282cfe649461.
Report an issue: GitHub.
Appendix: source
Thrown at modules/backend/vuecomponents/treeview/NodeDefinition.php:145
*/
public function __construct(string $label, string $key)
{
$this->label = $label;
$this->key = $key;
}
/**
* Sets tree branch display mode - tree or list.
* Only the root node display mode is considered.
*/
public function setDisplayMode(string $value)
{
if (!in_array($value, [self::DISPLAY_MODE_TREE, self::DISPLAY_MODE_LIST])) {
throw new SystemException('Invalid tree display mode: '.$value);
}
if ($this->groupBy) {
throw new SystemException('Treeview branch grouping is only supported for the LIST display mode');
}
$this->displayMode = $value;
return $this;
}
/**
* Determines whether multiple nodes can be selected.
* Only the root node property value is considered.
*/
public function setMultiSelect(bool $value)
{
$this->multiSelect = $value;
return $this;
}
View on GitHub (pinned to b608633a7e)