{"record":{"id":"4ab4204cb8cdca09","repo":"octobercms/october","slug":"treeview-branch-drag-and-drop-custom-mode-cannot-b","errorCode":null,"errorMessage":"Treeview branch drag and drop Custom mode cannot be combined with other modes","messagePattern":"Treeview branch drag and drop Custom mode cannot be combined with other modes","errorType":"exception","errorClass":"SystemException","httpStatus":null,"severity":"error","filePath":"modules/backend/vuecomponents/treeview/NodeDefinition.php","lineNumber":313,"sourceCode":"    {\n        $this->sortBy = $sortBy;\n\n        return $this;\n    }\n\n    /**\n     * Sets tree branch drag and drop mode - sort, move (or both), or custom.\n     * Only the root node drag and drop mode is considered.\n     */\n    public function setDragAndDropMode(array $mode)\n    {\n        foreach ($mode as $option) {\n            if (!in_array($option, [self::DND_MOVE, self::DND_SORT, self::DND_CUSTOM, self::DND_CUSTOM_EXTERNAL])) {\n                throw new SystemException('Invalid treeview branch drag and drop mode: '.$option);\n            }\n\n            if ($option === self::DND_CUSTOM && count($mode) > 1) {\n                throw new SystemException('Treeview branch drag and drop Custom mode cannot be combined with other modes');\n            }\n        }\n\n        if ($this->groupBy) {\n            throw new SystemException('Drag and drop is not supported for treeview branches with enabled Group By feature');\n        }\n\n        $this->dragAndDropMode = $mode;\n\n        return $this;\n    }\n\n    /**\n     * Sets optional grouping for a tree branch.\n     * Applies to root nodes only. Allows to group\n     * child nodes using a userData object property.\n     * Supported for the list display mode only.\n     */","sourceCodeStart":295,"sourceCodeEnd":331,"githubUrl":"https://github.com/octobercms/october/blob/b608633a7e8922487d91a8161499020121c3b3bf/modules/backend/vuecomponents/treeview/NodeDefinition.php#L295-L331","documentation":"Error \"Treeview branch drag and drop Custom mode cannot be combined with other modes\" thrown in octobercms/october.","triggerScenarios":"Thrown at modules/backend/vuecomponents/treeview/NodeDefinition.php:313 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":[],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"b608633a7e8922487d91a8161499020121c3b3bf","analyzedAt":"2026-08-21T04:24:57.515Z","schemaVersion":2},"datasetVersion":"2026-08-21T11:28:35.574Z"}