AngularJS checkbox filter

前端 未结 3 588
遥遥无期
遥遥无期 2020-12-04 13:42

I would like to filter the results.

There is a list of wines, my wish is when no checkbox is checked, the entire list of wine is displayed.

  • when only 1
3条回答
  •  孤城傲影
    2020-12-04 14:22

    Just to add onto @gkalpak answer, I found this codepen which allows you to provide the total amount left after an option is selected for each category.

    Change the ng-repeat from:

    {{ wine.name }} ({{ wine.category }})

    To

    {{ wine.name }} ({{ wine.category }})

    And with the input labels add:

    
    

提交回复
热议问题