HI!
I’m building a trello clone to learn ember and have small problem.
I have a board/index.hbs
template which just do {{render 'swimlanes/index' swimlanes}}
which renders the different lists of cards. swimlanes/index.hbs
renders its cards (using #each) and then {{render 'cards/new'}}
to display a simple form to create a new card.
So, in my cards/new
controller, in my createCard action, can I get the new card’s swimlane somehow?
I tried to just use needs: ['swimlane']
and then use this.get('controllers.swimlane').get('model')
. But it is undefined.
I can get to the current board using needs: ['board']
but it does not work with the swimlane so I guess it is due to how I render stuff.
Any ideas?