Currently working on a project using Cordova Ionic with AngularJS to develop an app. In this app, I am implementing a search filter for "apps". Each "app" has unique identifiers such as an id, name, and other attributes.
The issue I am facing is that the search filter seems to be functioning, but not accurately. It consistently returns the same two "apps" even when the search criteria do not match. I have confirmed that the name property I am filtering on is indeed a string, and I have even experimented with custom filters, yet the problem persists.
Despite researching and trying various solutions from different forums, including this one, the problem persists. It seems that the fact that "app" is an object might be causing the issue.
Below is the code for the search input line:
<input ng-model="apps[$index].name" type="search" placeholder="Search" class="searchInput">
And here is the ng-repeat code where the filter is applied:
<div ng-repeat="app in apps | filter:apps[$index]" ng-if="$index % per_row == 0" class="row">
I have tried variations like using "name" in both ng-model and filter, or apps[$index].name in both, among others, but the issue persists. Any suggestions on how to resolve this matter would be greatly appreciated!
Thank you for your assistance!