I recently answered a question on stackoverflow which bothered me a bit… and I was wondering if this is the “right way” to do it. It’s not really a question for stack overflow, it’s more a discussion… and possibly I might try to see if I can’t work this into the ember guides somehow because it’s a question which seems to crop up a lot.
It turns out what he wanted to do was have a list of anime (which were categorized - by using an asscoiation, with categories) which he could filter based on some checkboxes for each category.
The thing that I wasn’t sure if I’d solved in the “best way” was that he was using a setupController method on the route to load and set the categories… that doesn’t seem like it was right to me… because it would happen async… it felt to me like the category loading code should actually be in the model part of the route, not the setupController… if someone with a bit more experience could chime in on this, that’d make me a very happy chappy indeed. At that point, I feel it’d be very useful to have that example actually added to the ember docs, and I’d try to go about getting that in place as a guide or something.
This is the jsbin that I ended up creating: http://jsbin.com/datojebu/11/edit
It was in answer to this question: http://stackoverflow.com/questions/23155621/how-to-manage-multiple-checkboxes-in-ember/23179899#23179899
Any help would be greatly appreciated.