View で親コンポーネントを取得しようとしていますが、常に次のエラーが発生します。
Cannot call method 'getParent' of undefined
コードは次のとおりです。
initialize: function() {
this.callParent();
this.loadMates();
},
loadMates: function() {
var store = Ext.create('App.store.user.Mates');
store.getProxy().setExtraParam('userId', this.getParent().getUserId());
this.setStore(store);
}
初期化されたビューがundefined
. 「this」をパラメーターとしてプッシュしようとしましたが、成功しませんでした。
よろしくお願いします。
編集:
ここで sth を見つけました: http://www.sencha.com/forum/showthread.php?174406-this.parent-and-this.getParent()-always-return-undefined-in-initialize