繁体   English   中英

如何使用Angular.js在另一个ng-repeat中设置ng-repeat的过滤器

[英]How to set filter for ng-repeat inside another ng-repeat with Angular.js

我想通过仅显示当前月份的结果来设置第二个ng-repeat的过滤器以与第一个ng-repeat一起处理。 bookingsbooking.monthDatemonth类似

感谢您通过Angular.js帮助获得最佳实践

       .dataContainer{"ng-repeat"=>"month in months"}
          %h2
            %span.monthResa {{month}}

          .monthDetailContainer
            .fiche-inner{"ng-repeat"=>"booking in bookings | filter: ??? "}

注意:此摘录在HAML中,但是没有关系,因为我使用了预比较器来获取.html

Angular非常聪明:)

booking in bookings | filter: month

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM