Skip to content

Issue: filterFields Input Not Applied in PrimeNG MultiSelect Filtering #19342

@Indragith20

Description

@Indragith20

Describe the bug

Filter Fields in multiselect component not working as expected

Pull Request Link

#19341

Reason for not contributing a PR

  • Lack of time
  • Unsure how to implement the fix/feature
  • Difficulty understanding the codebase
  • Other

Other Reason

No response

Reproducer

https://primeng.org/multiselect

Environment

Primeng Version: v21
Angular Version: v21

Angular version

21.0.4

PrimeNG version

v21

Node version

No response

Browser(s)

No response

Steps to reproduce the behavior

Occurs in multiselect component

Expected behavior

When filterFields is provided:

<p-multiSelect
    [options]="items"
    optionLabel="name"
    [filter]="true"
    [filterFields]="['name', 'code']">
</p-multiSelect>

The filter logic should only match against the fields specified in filterFields (name, code).

Results should be filtered based on those fields instead of using default fields or implicit behavior.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type: BugIssue contains a bug related to a specific component. Something about the component is not working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions