How to filter multiple values (OR operation) in angularJS

前端 未结 20 885
清酒与你
清酒与你 2020-11-22 10:01

I want to use the filter in angular and want to filter for multiple values, if it has either one of the values then it should be displayed.

I have for

20条回答
  •  情深已故
    2020-11-22 10:28

    If you want to filter on Array of Objects then you can give

    filter:({genres: 'Action', key :value }.

    Individual property will be filtered by particular filter given for that property.

    But if you wanted to something like filter by individual Property and filter globally for all properties then you can do something like this.

    Where "filterObject" is an object for searching an individual property and "Search" will search in every property globally.

    ~Atul

提交回复
热议问题