我有以下内容:
$scope.filterObj = {"status":["active"],"categories":["u"]}
我需要排序的对象:
{"categories" : ["u", "a"], "status" : "active"}
我试图将其过滤为:
<tr ng-repeat="item in filtered = (projects | filter:filterObj.status:item.status) | orderBy : 'created_at'">
此示例适用于一个项目:
<tr ng-repeat="item in filtered = (projects | filter:{ status : 'finished' }) | orderBy : 'created_at'">
但不是数组