Note that there are some explanatory texts on larger screens.

plurals
  1. POError 404 while deploying extjs application using SenchaSDKTools
    primarykey
    data
    text
    <p>I am using <strong>SenchaSDKTools-2.0.0-beta3</strong> to build my project. After running following commands, app.jsb3,app-all.js,all-classes.js files get created but when I try to run the application after successfully replacing the <strong></strong> tag in index.html so as to include <strong>app-all.js</strong>, I get 404 - Not Found error for all the controllers I have inside <strong>app/controller</strong> </p> <pre><code>sencha create jsb -a index.html -p app.jsb3 -v sencha build -p app.jsb3 -v -d . </code></pre> <p>I have observed the app.jsb3 file it contains all my controllers with the path pointing to the <strong>app/controller</strong> of my application where as it is static and I want it to be dynamic so that I will be able to deply it using only two files <strong>(app.jsb3,app-all.js)</strong> with <strong>extjs</strong> folder and <strong>some css</strong> files.<br> Is there some other way to deploy it? </p> <p>index.html:<br> <code></p> <p> </p> <pre><code>&lt;link rel="stylesheet" type="text/css" href="extjs-4.1.0/resources/css/ext-all.css" /&gt; &lt;link rel="stylesheet" type="text/css" href="css/GroupTabPanel.css" /&gt; &lt;link rel="stylesheet" type="text/css" href="css/ort_override-2.css" /&gt; &lt;link rel="stylesheet" type="text/css" href="css/main-2.css" /&gt; &lt;!--[if gte IE 7]&gt; &lt;link rel="stylesheet" type="text/css" href="css/ort_override_ie7Plus.css" /&gt; &lt;![endif]--&gt; &lt;!--[if IE 7]&gt; &lt;link rel="stylesheet" type="text/css" href="css/ort_override_ie7.css" /&gt; &lt;![endif]--&gt; &lt;!--[if IE 6]&gt; &lt;link rel="stylesheet" type="text/css" href="css/ort_override_ie6.css" /&gt; &lt;![endif]--&gt; &lt;script type="text/javascript" src="extjs-4.1.0/ext.js"&gt;&lt;/script&gt; &lt;script type="text/javascript" src="app-all.js"&gt;&lt;/script&gt; &lt;script type="text/javascript" src="sha256.js"&gt;&lt;/script&gt; &lt;script src="jQuery/jquery-1.7.2.min.js"&gt;&lt;/script&gt; &lt;script type="text/javascript"&gt; if (typeof console == "undefined" || typeof console.log == "undefined") { var console = { log: function() {} }; } Ext.Loader.setPath({ 'Ext.ux': 'extjs-4.1.0/examples/ux' }); Ext.require([ 'Ext.ux.GroupTabPanel', ]); function showLoginInfo(){ if(document.getElementById("divInfo").style.display=="none"){ //document.getElementById("divInfo").style.display=""; $("#divInfo").slideDown('fast'); //document.getElementById("divLoginInfo").className="divLoginInfo selected"; }else{ //document.getElementById("divInfo").style.display="none"; $("#divInfo").slideUp('fast'); //document.getElementById("divLoginInfo").className="divLoginInfo"; } } &lt;/script&gt; </code></pre> <p> </p> <p></code> </p> <p>app.js: </p> <p>// handle errors that are thrown not using Ext.raise() window.onerror = function(msg, url, lineNumber) { alert(msg+' \rurl: '+url+' \rline: '+lineNumber) //console.warn('%s\rurl: %s\rline: %d', msg, url, lineNumber); //return true; //true means don't propogate the error } </p> <p>function OnApplicationExit() { ORT.app.fireEvent('logout'); }</p> <p>function ShowError(title, msg, obj) { Ext.Msg.show({ scope: this, title: title, msg: msg, buttons: Ext.Msg.OK, icon: Ext.MessageBox.ERROR, fn: function(btn) { if("ok" == btn) { if(obj &amp;&amp; obj.handler) { obj.handler(obj.code); } } } }); }</p> <p>Ext.application({</p> <pre><code>requires: [ 'ORT.Configuration', 'Ext.grid.plugin.CellEditing' ], name: 'ORT', appFolder: 'app', autoCreateViewport: true, controllers: ['Dashboard', 'MySurveys', 'SurveyBuilder', 'UserManager', 'CompanyManager'], launch: function() { console.log('ORT::launch()'); ORT.app = this; Ext.Error.notify = false; // prevent ie6 and ie7 popup Ext.Error.handle = this.onApplicationError; // handle errors raised by Ext.Error.raise() //throw 'Testing: General error raised by ORT application'; Ext.Ajax.on('requestexception', this.onAjaxRequestException, this); ORT.app.on({ scope: this, servererror : 'onServerError', ajaxerror : 'onAjaxRequestException' }); ORT.app.fireEvent('pageload'); /* Ext.getBody().mask('Loading Online Research Tool...'); Ext.onReady(function() { setTimeout(function(){ Ext.getBody().unmask(); }, 250); }); */ }, handleError: function(code) { console.log('ORT::handleError()'); if('401' == ''+code) { } else if('403' == ''+code) { ORT.app.fireEvent('logout'); } else { console.log('No handler found for error ' + code); } }, onServerError: function (errCode, errMsg) { console.log('ORT::onServerError()'); var title = 'Unknown Server Error'; if(errCode) { title = 'Server Error: ' + errCode; } var msg = 'No error description found!' if(errMsg) { msg = errMsg } ShowError(title, msg, {code: errCode, handler: this.handleError}); //this.handleError(errCode); }, onApplicationError: function(error){ console.log('ORT::onApplicationError()'); var title = 'Application Error'; if(error['error code']) { title = 'Application Error: ' + error['error code']; } var msg = 'No error description found!' if(error.msg) { msg = error.msg } ShowError( title, msg); return true; }, onAjaxRequestException: function(conn, response, options, eOpts) { console.log('ORT::onAjaxRequestException()'); var title = 'Communication Error'; if(response.status) { title = 'Communication Error: ' + response.status; } var message; switch (response.status) { case 403: //this.onAuthenticationRequired(conn, response, options, eOpts); message = 'Your session is not valid now, please login to the site and continue.'; break; case 401: //this.onRequestUnauthorized(conn, response, options, eOpts); message = 'You are not authorized to use this feature!'; break; case 404: message = 'Resource [ '+response.request.options.url+ ' ] '+response.statusText; break; default: message = response.statusText; break; } ShowError(title, message); this.handleError(response.status); } </code></pre> <p>});</p>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload