From 5fd37ae2c3c77e3d48d53f4658e1a2de046d8c11 Mon Sep 17 00:00:00 2001 From: zaartix Date: Tue, 7 Nov 2017 09:57:27 +0400 Subject: [PATCH] Form field can be not mapped If form have field not mapped there is throws error "@Entity has no field or association named @field" --- Filter/FilterBuilderUpdater.php | 3 +++ 1 file changed, 3 insertions(+) diff --git a/Filter/FilterBuilderUpdater.php b/Filter/FilterBuilderUpdater.php index 66c927e..4eb7497 100644 --- a/Filter/FilterBuilderUpdater.php +++ b/Filter/FilterBuilderUpdater.php @@ -124,6 +124,9 @@ protected function addFilters(FormInterface $form, QueryInterface $filterQuery, /** @var $child FormInterface */ foreach ($form->all() as $child) { $formType = $child->getConfig()->getType()->getInnerType(); + if ($child->getConfig()->getMapped() === false) { + continue; + } // this means we have a relation if ($child->getConfig()->hasAttribute('add_shared')) {