From ca30c3cef06f1236346f50ef3f6f7e987f7664b9 Mon Sep 17 00:00:00 2001 From: Sam Georges Date: Tue, 24 Jun 2014 18:53:05 +1000 Subject: [PATCH] Fixes minor bug --- modules/backend/behaviors/RelationController.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) 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);