diff --git a/modules/backend/behaviors/RelationController.php b/modules/backend/behaviors/RelationController.php index ed729d69b..597a17da0 100644 --- a/modules/backend/behaviors/RelationController.php +++ b/modules/backend/behaviors/RelationController.php @@ -556,10 +556,12 @@ class RelationController extends ControllerBehavior $config = $this->makeConfig($this->config->list); $config->model = $this->relationModel; $config->alias = $this->alias . 'ViewList'; - $config->noRecordsMessage = $this->config->emptyMessage; $config->recordOnClick = sprintf("$.oc.relationBehavior.clickManageListRecord('%s', :id)", $this->field); $config->showCheckboxes = true; + if ($emptyMessage = $this->getConfig('emptyMessage')) + $config->noRecordsMessage = $emptyMessage; + $widget = $this->makeWidget('Backend\Widgets\Lists', $config); $widget->bindEvent('list.extendQueryBefore', function($host, $query) { $this->relationObject->setQuery($query);