Sfoglia il codice sorgente

Erreur 500 : Argument 2 passed to Lc\SovBundle\Field\Filter\FilterManager::applyFilter() must be an instance of EasyCorp\Bundle\EasyAdminBundle\Dto\FieldDto, null given #623

develop
Guillaume Bourgeois 2 anni fa
parent
commit
1a4a3c1f71
1 ha cambiato i file con 6 aggiunte e 3 eliminazioni
  1. +6
    -3
      Controller/AbstractAdminController.php

+ 6
- 3
Controller/AbstractAdminController.php Vedi File

@@ -64,9 +64,12 @@ abstract class AbstractAdminController extends SovAbstractAdminController
$controller->configureFields($autocompleteContext['originatingPage'])
)->getByProperty($autocompleteContext['propertyName']);

$filterManager = $this->get(FilterManager::class);
$filteredValue = ['value' => $context->getRequest()->query->get('q')];
$filterManager->applyFilter($repositoryQuery, $field, $filteredValue);
if($field) {
$filterManager = $this->get(FilterManager::class);
$filteredValue = ['value' => $context->getRequest()->query->get('q')];
$filterManager->applyFilter($repositoryQuery, $field, $filteredValue);
}

$repositoryQuery->select('.' . $autocompleteContext['propertyName']);

$responses = array();

Loading…
Annulla
Salva