I have a $scope.myData object which has empty values in message object.
$scope.myData = [
{
"ID" : "001",
"deviceName":"sanjit",
"Message" : "test1"
},{
"ID" : "002",
"deviceName":"gan",
"Message" : "test2"
},{
"ID" : "003",
"deviceName":"dine",
"Message" : ""
},{
"ID" : "004",
"deviceName":"sam",
"Message" : "test4"
},{
"ID" : "005",
"deviceName":"dhar",
"Message" : " "
},{
"ID" : "006",
"deviceName":"gau",
"Message" : "test6"
},{
"ID" : "007",
"deviceName":"venk",
"Message" : "test7"
}
]
I perform dir-paginate in a tr tag like below
<br/><b> dir-paginate="dev in myData | filter:{deviceName:q,message:loc}></b>
<br/>
and using two inputs for filter
<br/>
Device Name: <b>ng-model="q"</b>
<br/>
Message: <b>ng-model="loc"</b>
When I search for a message in the input field with ng-model="loc", I will get the correct result list (001,002,004,006,007)
When I clear the field "loc" I will not get complete results but only the above 5 results (001,002,004,006,007), i.e. after clearing the filter field "loc" , I'm not getting the objects with empty values in message.
Please let me know what is wrong?