Score:0

Filter Entity Queue by Taxonomy Term ID

cn flag

I am loading am entity queue and placing it on a node as a block. Using contextual filters in a view I am getting the term ID from the current node. I need to use that term ID to filter down my entity queue. My current code loads the entire queue. Is it possible to filter nodes in the queue by the current tid?

This is how I am loading the queue within hook_views_query_alter

$query_subqueue = \Drupal::entityQuery('entity_subqueue')
->condition('queue', 'yearbook');
$result = $query_subqueue->execute();
zanvidmar avatar
sa flag
Did you tried with adding `->condition('items', $tid)` to yourquery?
mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.