Created
May 9, 2013 02:43
-
-
Save arbales/5545215 to your computer and use it in GitHub Desktop.
Actions specified inside the {{render}} helper appear not to reach their specified controller.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# This controller doesn't manage a model. | |
# | |
Ab.HeaderController = Ember.Controller.extend | |
needs: ['currentUser'] | |
toggleMode: -> | |
@get('controllers.currentUser').toggleProperty 'usesCompactLayout' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# For debugging purposes, I wanted to see if I could direct the action to the view, | |
# and then forward it, but this `toggleMode` is also not reached by the action helper. | |
Ab.HeaderView = Ember.View.extend() | |
# toggleMode: -> @get('controller').send('toggleMode', arguments...) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Nevermind I guess?