Problem/Motivation

I would like to add a facet with views core facet but I can't edit facet after creation

The website encountered an unexpected error. Please try again later.
Error: Call to undefined method Drupal\core_views_facets\Plugin\facets\facet_source\CoreViewsExposedFilter::getIndex() in Drupal\facets\Plugin\facets\processor\BooleanItemProcessor->supportsFacet() (line 101 of modules/contrib/facets/src/Plugin/facets/processor/BooleanItemProcessor.php).

Drupal\facets\Plugin\facets\processor\BooleanItemProcessor->supportsFacet() (Line: 231)
Drupal\facets\Form\FacetForm->form() (Line: 19)
Drupal\core_views_facets\Form\ViewsFacetForm->form() (Line: 106)
Drupal\Core\Entity\EntityForm->buildForm()
call_user_func_array() (Line: 532)
Drupal\Core\Form\FormBuilder->retrieveForm() (Line: 278)
Drupal\Core\Form\FormBuilder->buildForm() (Line: 73)
Drupal\Core\Controller\FormController->getContentResult() (Line: 39)
Drupal\layout_builder\Controller\LayoutBuilderHtmlEntityFormController->getContentResult()
call_user_func_array() (Line: 123)
Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->Drupal\Core\EventSubscriber\{closure}() (Line: 578)
Drupal\Core\Render\Renderer->executeInRenderContext() (Line: 124)
Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->wrapControllerExecutionInRenderContext() (Line: 97)
Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->Drupal\Core\EventSubscriber\{closure}() (Line: 158)
Symfony\Component\HttpKernel\HttpKernel->handleRaw() (Line: 80)
Symfony\Component\HttpKernel\HttpKernel->handle() (Line: 57)
Drupal\Core\StackMiddleware\Session->handle() (Line: 47)
Drupal\Core\StackMiddleware\KernelPreHandle->handle() (Line: 106)
Drupal\page_cache\StackMiddleware\PageCache->pass() (Line: 85)
Drupal\page_cache\StackMiddleware\PageCache->handle() (Line: 47)
Drupal\Core\StackMiddleware\ReverseProxyMiddleware->handle() (Line: 52)
Drupal\Core\StackMiddleware\NegotiationMiddleware->handle() (Line: 23)
Stack\StackedHttpKernel->handle() (Line: 717)
Drupal\Core\DrupalKernel->handle() (Line: 19)

I use facets with drupal 9.2.7

Steps to reproduce

Created views with taxonomy exposed filter as dropdown

Added facet of type core views

Regards

Command icon Show commands

Start within a Git clone of the project using the version control instructions.

Or, if you do not have SSH keys set up on git.drupalcode.org:

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

creatile created an issue. See original summary.

mkindred’s picture

I'm seeing the same thing with 9.2.8, attempting to edit a facet created from an exposed taxonomy filter.

slasher13’s picture

mkindred’s picture

@slasher13 that patch fixed my problem. Vielen Dank!

@creatile were you able to resolve your problem? If so, perhaps we can close this issue.

dwkitchen’s picture

Version: 8.x-1.2 » 8.x-1.x-dev
Component: Miscellaneous » Code
Status: Active » Needs work

This will be fixed in the 2.x branch, but anyone still on 1.8 of Facets will need the patch.

Propose that Core Views Facets updates dependency to require Facets ^2.0

dwkitchen’s picture

Title: Impossible to edit Facet » Impossible to edit Facet with Facet module < 2.0

dwkitchen’s picture

Status: Needs work » Needs review

  • slasher13 committed b423407 on 8.x-1.x authored by dwkitchen
    Issue #3245999 by dwkitchen, slasher13: Impossible to edit Facet with...
slasher13’s picture

slasher13’s picture

Status: Needs review » Fixed

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.