I’m trying to place filter controls into the Right side-menu which will apply to the list displayed in the side-menu content. However, the side-menu content doesn’t seem to recognize the filter. The control I am using in the side-menu is a drop-down box.
If I place the code within Side-menu content, then everything works fine.
I suppose it has something to do scope of variables, but I can’t seem to figure out how to solve this. Any help will be much appreciated.
I would recommend creating a state service (or similar name) which stores the filtered values.
The right hand menu can then update the service via it’s controller, and the main content controller could watch for changes in the state services value. This can be applied throughout your app.
If you need examples let me know, but I’m not about until Monday.
I know this is an old thread, but I haven’t found this addressed anywhere else directly. I’ve been struggling with this as well would love some sample code for how to make a filter work from the side menu.
I see s3raph’s filter example wasn’t an example of how to do a filter in the side menu, it was a filter that works when in the content of a page but not in the side menu. @s3raph, please disregard my comment. thanks.