octobercms/october · error · ApplicationException
backend::lang.model.missing_relation
Error message
backend::lang.model.missing_relation
What it means
Error "backend::lang.model.missing_relation" thrown in octobercms/october.
Source
Thrown at modules/backend/behaviors/RelationController.php:392
// Configuration details
if (!$this->relationHasField($field)) {
throw new ApplicationException(Lang::get('backend::lang.relation.missing_definition', compact('field')));
}
$this->applyExtraConfig($field);
$this->alias = camel_case('relation ' . HtmlHelper::nameToId($field));
$this->config = $this->makeConfig($this->originalConfig->{$field}, $this->requiredRelationProperties);
$this->controller->relationExtendConfig($this->config, $this->field, $this->model);
$this->manageId = $this->getManageIdForField($field);
$this->pivotId = post('pivot_id');
$this->foreignId = post('foreign_id');
[$this->sessionKey, $this->relationSessionKey] = $this->getSessionKeysForField($field);
// Relationship details
[$nestedModel, $nestedField] = $this->makeNestedRelationModel($this->model, $this->config->valueFrom ?? $field);
if (!$nestedModel->hasRelation($nestedField)) {
throw new ApplicationException(Lang::get('backend::lang.model.missing_relation', ['class' => get_class($nestedModel), 'relation' => $nestedField]));
}
$this->relationParent = $nestedModel;
$this->relationName = $nestedField;
$this->relationType = $nestedModel->getRelationType($nestedField);
$this->relationObject = $nestedModel->{$nestedField}();
$this->relationModel = $this->relationObject instanceof HasOneOrMany
? $this->relationObject->make()
: $this->relationObject->getRelated();
$this->readOnly = $this->getConfig('readOnly');
$this->popupSize = $this->getConfig('popupSize', 950);
$this->externalToolbarBus = $this->getConfig('externalToolbarBus');
$this->eventTarget = $this->evalEventTarget();
$this->deferredBinding = $this->evalDeferredBinding();
$this->viewMode = $this->evalViewMode();
$this->manageMode = $this->evalManageMode();
$this->manageTitle = $this->evalManageTitle();View on GitHub (pinned to b608633a7e)
When it happens
Trigger: Thrown at modules/backend/behaviors/RelationController.php:392 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/08d588e1af3919f9.
Report an issue: GitHub.