service portal angular search filter not working

nis
Tera Expert

I am trying to create a simple search filter on the Service Portal.
I have cloned the data table widget and added a search filter. Changes made have been highlighted.

find_real_file.png

Could you let me know what is wrong? Since the Search is not working here.

Expected is to get list of all incidents with the word network available in any of the columns listed. I do not want to use Keyword Search since its a server side search and is pretty slow and also does not allow search on Date fields and common terms.

find_real_file.png

Regards,

Nisha

1 ACCEPTED SOLUTION

dvp
Mega Sage
Mega Sage

Can you replace the repeat statement with below   line and try it



<tr ng-repeat = "item in data.list | filter: data.list.searchText track by item.sys_id">


View solution in original post

10 REPLIES 10

Inactive_Us1474
Giga Guru

Hi,



Try using ng-model ="searchText" only and change in filter : searchText



Hope it helps.


Akhil


Already tried that. It dint work ☹


After changing the ng-model do I need to make any changes in the Client Script / Server Script?


Also, this behavior is only when I have cloned the DataTable widget and then add this code.


If I create a new widget from scratch and query they incident table then the filter works fine.


But I want to re-use the functionalities of the DataTable and add additional free text search feature.


dvp
Mega Sage
Mega Sage

Can you replace the repeat statement with below   line and try it



<tr ng-repeat = "item in data.list | filter: data.list.searchText track by item.sys_id">