Angularjs uib-typeahead object in array

54 Views Asked by At

I am trying to implement typeahead by searching through an array of objects. How do i do so? I only know how to search through an array but not an array of object

Array of object

enter image description here

HTML:

   <input type="text" class="searchFeature" ng-keyup="$event.keyCode == 13 && 
   searchFunction()" ng-model="selected" uib-typeahead="value for value in 
   allTheme | filter:$viewValue | limitTo:7" placeholder="Start your search here.">

The result i am getting :

enter image description here

PS: Is it possible to get just the "THEMENAME" and "Category" object and filter it in my typeahead search?

1

There are 1 best solutions below

0
Venkatesh K On

try

uib-typeahead="value.THEMENAME for value in allTheme | filter:$viewValue | limitTo:7"