Queue is always required when using "Limit to a specific entity queue" even when specifying that this relation is not required from views, this results in that you cannot add multiple sorts and having a "not in the queue" relationship.

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

josebc created an issue. See original summary.

amateescu’s picture

Status: Needs work » Active

Interesting :) Do you think you can investigate a bit and post a patch for this? It would be nice to have it fixed in alpha5.

josebc’s picture

Status: Active » Needs work

on it :)

josebc’s picture

Status: Needs work » Active
josebc’s picture

Status: Active » Needs review
FileSize
1.64 KB

moved condition to join instead of where
patch attached

Rajab Natshah’s picture

Rewarded work Jose!

Testing :)

Rajab Natshah’s picture

Assigned: josebc » Unassigned
Status: Needs review » Reviewed & tested by the community
amateescu’s picture

Status: Reviewed & tested by the community » Needs review
FileSize
1.69 KB
1.89 KB

Nice work! I tested the patch from #5 and it fixes only the first part of the problem: the queue is no longer required unless the relationship itself is required.

However, the "not in the queue" filter still doesn't behave as expected.

I was able to fix it easily by removing the extra WHERE from \Drupal\entityqueue\Plugin\views\filter\EntityQueueInQueue.

Can you please test this patch and let me know if everything works correctly now?

Rajab Natshah’s picture

Testing ......

amateescu’s picture

@RajabNatshah, still testing? :)

Rajab Natshah’s picture

  • amateescu committed b3fd10b on 8.x-1.x
    Issue #2821631 by amateescu, josebc: Queue is always required when using...
amateescu’s picture

Status: Needs review » Fixed

Committed the patch from #8 to 8.x-1.x. Thanks everyone :)

josebc’s picture

Status: Fixed » Needs work

Latest patch will not limit the results to queue, moving parent::query(); above makes it ignore the extra

amateescu’s picture

Status: Needs work » Fixed

Status: Fixed » Closed (fixed)

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