Here is a sample of the data I am working with:
{"createDate":"2014-04-22T08:14:10.285Z",
"desc":"Hello hello",
"gradeFrom":"4",
"gradeTo":"7",
"owner":"example@example.com",
"schoolType":{
"name":"Primary School"
},
"subject":{
"En":false,
"Ge":false,
"Re":true,
"Sh":false,
"SvA":false,
"Tn":false
},
"title":"Testing testing"}
My goal is to filter the data so that when a user clicks a button and sets $scope.searchText
to "Re":true, only the data entries where "subject": {"Re":true} are displayed.
I am currently using filtering with a search string, however, it only filters through the top layer properties like "createDate", "desc", and not the nested "subject" property.
<tr ng-repeat="lesson in lessons | orderByPriority | filter:searchText | orderBy:'createDate':true">