martinrame
10 Feb 2012, 10:28 AM
In an event handler in one controller, I need to open a view and its associated controller, currently I'm doing this:
mycontroller = this.getController('DEMO.controller.UserCRUD');
myview = Ext.create('DEMO.view.UserCRUD', {});
myview.show();
mycontroller.init();
But this doesn't looks nice. Is there a way to autommatically link the view and controller in a way that instantiating one of them, the other is created automatically?.
Thanks in advance,
Leonardo.
mycontroller = this.getController('DEMO.controller.UserCRUD');
myview = Ext.create('DEMO.view.UserCRUD', {});
myview.show();
mycontroller.init();
But this doesn't looks nice. Is there a way to autommatically link the view and controller in a way that instantiating one of them, the other is created automatically?.
Thanks in advance,
Leonardo.