0
Ich bin neue Extjs Benutzer Ich habe Controller in der Navigation definiert, aber nicht funktioniert. Bitte helfen Sie.Extjs Controller definieren innerhalb Navigation
Ext.define('MyApp.controller.Navigation', {
extend: 'Ext.app.Controller',
alias: 'widget.navigationController',
views: ['Navigation'],
refs : [{
ref: 'navigationView',
selector: 'navigation'
}],
init: function(application){
console.log('controller init');
this.control({
'navigation': {
'golocale': this.goLocale,
'gobrand': this.goBrand,
'gosize': this.goSize,
'goarticle': this.goArticle,
'gogender': this.goGender,
'goprofile': this.goProfile,
scope: this
}
});
},
goLocale: function(link){
console.log('locale clicked');
console.dir(link);
},
goBrand: function(link){
console.log('brand clicked');
// Also tried:
// var viewport = this.getView('Viewport').create();
var viewport = link.up('viewport');
console.dir(viewport);
},
Konsole Fehler unten
MyApp.controller.Navigation.addListener(): The specified callback function is undefined
Wo sind die anderen Methoden? 'goSize',' goArticle' etc? Das ist wahrscheinlich der Grund für die Ausnahme. –