Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Calling from controller #1

Open
bluee opened this issue Feb 1, 2015 · 2 comments
Open

Calling from controller #1

bluee opened this issue Feb 1, 2015 · 2 comments

Comments

@bluee
Copy link

bluee commented Feb 1, 2015

Is it possible to call this filter from the controller?

I have been trying this:
$filter('inArray')(data, { StatusInt: item.filter })

But not sure how to pass the parameters: filterBy:"StatusInt"

@cyberdelphos
Copy link
Owner

Not very sure what you're trying to achieve...
You use it like this:
$filter('inArray')(data,"StatusInt") where "data" (the first argument of this filter) is your array to match against, and "StatusInt" (second argument) is the property you want to match against the array.

It would be nice if you could provide more info about your problem.

 On Sunday, February 1, 2015 2:09 AM, bluee <[email protected]> wrote:

Is it possible to call this filter from the controller?I have been trying this:
$filter('inArray')(data, { StatusInt: item.filter })But not sure how to pass the parameters: filterBy:"StatusInt"—
Reply to this email directly or view it on GitHub.

@bluee
Copy link
Author

bluee commented Feb 2, 2015

I'm just basically trying to run the $filter inArray from a controller than from a view. So I'm trying to achieve the same as in your example here on Github.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants