Skip to content

Instantly share code, notes, and snippets.

@mansona mansona/application.js Secret
Created Jan 20, 2016

Embed
What would you like to do?
Action handler for a "bad" open modal
...
openModal(modal, options) {
var controllerName = options && options.controller || 'modal';
var controller = this.controllerFor(controllerName);
controller.set('content', options && options.data || {});
Ember.run.scheduleOnce('afterRender', this, function() {
this.render(modal, {
into: 'application',
outlet: 'modal',
controller: controllerName
});
});
},
...
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.