I'm trying to open a modal dialog when someone tries to navigate away from a page with a form that isn't complete. I have the modal template built, but I can't figure out how to implement it. Here's what I have:
actions: {
willTransition: function( transition ){
var model = this.currentModel;
if( model.get( 'isDirty' ) ){
this.render( 'modal-confirmation', {
into: 'application',
outlet: 'modal'
} );
}
}
}
NOTE: The dirty checking works and I can generate a prompt, but this modal thing is not working
Aucun commentaire:
Enregistrer un commentaire