Venkatesh S Venkatesh S - 1 year ago 104
AngularJS Question

how to use services function in filters (AngularJS)

I have a filter that returns values based on the ID. These values are dynamically fetched and stored in an array using SERVICES. Now I want to use this SERVICE function to fetch values dynamically and that will be used in the filter.

How can I call a service function in the filter?

Answer Source
app.filter('MyCustomFilter', ['ServiceHelper', function(ServiceHelper){
  return function(id) {
Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download