- Issue created by @lelkneralfaro
I lied, tomselect was not the problem, the issue was that the data export display filter was using Autocomplete and the page filter was using Dropdown
I have a view display with a csv export link provided by the views_data_export → module and when I have applied a filter using the tomselect widget take over of the multiselect I get this error:
The website encountered an unexpected error. Try again later.<br><br><em class="placeholder">TypeError</em>: Drupal\Core\Entity\Element\EntityAutocomplete::Drupal\Core\Entity\Element\{closure}(): Argument #1 ($item) must be of type array, string given in <em class="placeholder">Drupal\Core\Entity\Element\EntityAutocomplete::Drupal\Core\Entity\Element\{closure}()</em> (line <em class="placeholder">126</em> of <em class="placeholder">core/lib/Drupal/Core/Entity/Element/EntityAutocomplete.php</em>). <pre class="backtrace">array_map(Object, Array) (Line: 126)
Drupal\Core\Entity\Element\EntityAutocomplete::valueCallback(Array, Array, Object)
call_user_func_array(Array, Array) (Line: 1259)
Drupal\Core\Form\FormBuilder->handleInputElement('views_exposed_form', Array, Object) (Line: 999)
Drupal\Core\Form\FormBuilder->doBuildForm('views_exposed_form', Array, Object) (Line: 1069)
Drupal\Core\Form\FormBuilder->doBuildForm('views_exposed_form', Array, Object) (Line: 579)
Drupal\Core\Form\FormBuilder->processForm('views_exposed_form', Array, Object) (Line: 326)
Drupal\Core\Form\FormBuilder->buildForm('\Drupal\views\Form\ViewsExposedForm', Object) (Line: 134)
Drupal\views\Plugin\views\exposed_form\ExposedFormPluginBase->renderExposedForm() (Line: 1298)
Drupal\views\ViewExecutable->build() (Line: 75)
Drupal\views_data_export\Plugin\views\display\DataExport::buildBatch(Object, Array) (Line: 53)
Drupal\views_data_export\Plugin\views\display\DataExport::buildResponse('program_clients_by_waitlist_no_search_api', 'data_export_1', Array) (Line: 56)
Drupal\views\Routing\ViewPageController->handle('program_clients_by_waitlist_no_search_api', 'data_export_1', Object)
call_user_func_array(Array, Array) (Line: 123)
Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->Drupal\Core\EventSubscriber\{closure}() (Line: 638)
Drupal\Core\Render\Renderer->executeInRenderContext(Object, Object) (Line: 121)
Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->wrapControllerExecutionInRenderContext(Array, Array) (Line: 97)
Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->Drupal\Core\EventSubscriber\{closure}() (Line: 181)
Symfony\Component\HttpKernel\HttpKernel->handleRaw(Object, 1) (Line: 76)
Symfony\Component\HttpKernel\HttpKernel->handle(Object, 1, 1) (Line: 53)
Drupal\Core\StackMiddleware\Session->handle(Object, 1, 1) (Line: 48)
Drupal\Core\StackMiddleware\KernelPreHandle->handle(Object, 1, 1) (Line: 28)
Drupal\Core\StackMiddleware\ContentLength->handle(Object, 1, 1) (Line: 32)
Drupal\big_pipe\StackMiddleware\ContentLength->handle(Object, 1, 1) (Line: 116)
Drupal\page_cache\StackMiddleware\PageCache->pass(Object, 1, 1) (Line: 90)
Drupal\page_cache\StackMiddleware\PageCache->handle(Object, 1, 1) (Line: 48)
Drupal\Core\StackMiddleware\ReverseProxyMiddleware->handle(Object, 1, 1) (Line: 51)
Drupal\Core\StackMiddleware\NegotiationMiddleware->handle(Object, 1, 1) (Line: 36)
Drupal\Core\StackMiddleware\AjaxPageState->handle(Object, 1, 1) (Line: 51)
Drupal\Core\StackMiddleware\StackedHttpKernel->handle(Object, 1, 1) (Line: 741)
Drupal\Core\DrupalKernel->handle(Object) (Line: 19)
</pre>
Active
1.0
Code
I lied, tomselect was not the problem, the issue was that the data export display filter was using Autocomplete and the page filter was using Dropdown