O'Reilly logo

Enterprise Application Development with Ext JS and Spring by Gerald Gierer

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Let's log on!

It is now time to enable our controllers and test the functionality. Update the Application.js file as displayed in the following code:

Ext.define('TTT.Application', { name: 'TTT', extend: 'Ext.app.Application', requires: ['TTT.view.Viewport', 'TTT.view.LogonWindow'], models: ['User'], controllers: ['MainController', 'UserController'], stores: ['User'], init: function(application){ TTT.URL_PREFIX = 'ttt/'; Ext.Ajax.on('beforerequest', function(conn, options, eOpts){ options.url = TTT.URL_PREFIX + options.url; }); }, launch: function() { var me = this; TTT.console = function(output) { if (typeof console !== 'undefined') { console.info(output); } }; me.logonWindow = Ext.create('TTT.view.LogonWindow'); me.logonWindow.show(); }, doAfterLogon: ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required