protected function autocompleteAction()
    {
        $results = $this->get('easyadmin.autocomplete')->find(
            $this->request->query->get('entity'),
            $this->request->query->get('query'),
            $this->request->query->get('page', 1)
        );

        return new JsonResponse($results);
    }
protected function autocompleteAction()
    {
        $results = $this->get('easyadmin.autocomplete')->find(
            $this->request->query->get('entity'),
            $this->request->query->get('query'),
            $this->request->query->get('page', 1)
        );

        return new JsonResponse($results);
    }
protected function autocompleteAction ( ) { $ results = $ this -> get ( 'easyadmin.autocomplete' ) -> find ( $ this -> request -> query -> get ( 'entity' ) , $ this -> request -> query -> get ( 'query' ) , $ this -> request -> query -> get ( 'page' , 1 ) ) ; return new JsonResponse ( $ results ) ; }
The method that returns the values displayed by an autocomplete field
based on the user's input.

@return JsonResponse
The method that returns the values displayed by an autocomplete field based on the user s input .