I have a method:
<span ng-init="getJobApplicantsList(jobId)">(number should be display here)</span>
Is there a way to display the data without having to store it in a scope variable?
I need to use this method in many places.
This is my controller:
var set = [blah,blah];//object
$scope.getJobApplicantsList = function(jobId) {
findByMatchingProperties(set, { jobId: jobId }).length; // Here I have a function that returns a number, for example: 250
}
I want to achieve something like this:
<span>{{getJobApplicantsList(jobId)}}</span>