Problem/Motivation

Adding the filter inside an OR filter group doesn't put the condition inside an OR condition group.

Steps to reproduce

1. Add (normal) reference filter with operator is empty
2. Add entityreference filter (same field from above)
3. Create filter group with OR operator and add the 2 filters inside the filter group

Proposed resolution

ManyToOneHelper's "Reduce duplicates" will create the correct query so if we
show "Reduce duplicates" field in the value form/build options form, we can set that in the filter and it will fix the filter group.

Calling $this->helper->buildOptionsForm($form, $form_state); inside EntityReferenceFilterViewResult::valueForm() will do the trick

Comments

vhin0210 created an issue. See original summary.

vhin0210’s picture

StatusFileSize
new525 bytes
maximkashuba’s picture

StatusFileSize
new881 bytes

hi, @vhin0210
Thank you for your response and the patch,
i checked and changed it a bit by adding this field only to not exposed entityreference filters.

  • maximkashuba committed cf777fb on 8.x-1.x
    #3202036. Adds reduce_duplicates option for not exposed erf filters
    
maximkashuba’s picture

Status: Needs review » Fixed
maximkashuba’s picture

Status: Fixed » Closed (fixed)