Hi, I'm working on
SA change app.json file adding
nothing more.
To fix the problem I had to remove the line from app.json file and add the required file in app.js file
Do you thing it's a SA bug o I did something wrong when I added the Override?
Override field Spinner doesn't work on production app
framework: | Sencha Touch 2.4.x |
I create a spinner override as described in this conversation.
In order to reproduce the problem, I created the Override I click on the component with the right button and the click on "Create override for this class"
The ovverride created a file /app/override/field/Spinner.js
The code was:
Code:
Ext.define('MyApp.override.field.Spinner', { override: 'Ext.field.Spinner',
applyValue : function(value) {
value = parseFloat(value);
if (isNaN(value) || value === null) {
value = this.getDefaultValue();
}
return this.callSuper([value]);
}
});
SA change app.json file adding
Code:
"js": [
...
{
"path": "app/override/field/Spinner.js",
"x-compile": true
},
...
],
nothing more.
When I launch the command "sencha app build production" there is an error in the app:
Code:
Error evaluating http://ift.tt/1BrG3Sr with message: TypeError: undefined is not a function
To fix the problem I had to remove the line from app.json file and add the required file in app.js file
Code:
Ext.application({
name: 'MyApp',
requires: [
'Ext.MessageBox',
'MyApp.override.field.Spinner'
],
//...
});
Do you thing it's a SA bug o I did something wrong when I added the Override?
Thanks for your support.
Regards
Override field Spinner doesn't work on production app
Aucun commentaire:
Enregistrer un commentaire