-
5 Nov 2012 4:16 PM #11
thank you again very much... just to complete
is the following code the consequent only solution or there is a more elegant way to address it?
Code:refs: { info1: '#infoview1', info2: '#infoview2' }, control: { 'info1': { activate: 'fillData' }, 'info2': { activate: 'fillData2' } } ...
AlessandroCode:fillData2: function() { this.fillData(2); }, fillData: function(level) { var store = Ext.getStore('infostore'); switch (level) { case 1: default: var panel = this.getInfo1(); break; case 2: var panel = this.getInfo2(); break; } store.load({ ....
-
5 Nov 2012 5:21 PM #12
Have you logged what is 'level' when 'info1' activate?
Code:control: { 'info1': { activate: 'fillData' }, 'info2': { activate: 'fillData' } } ... fillData: function(level) { var store = Ext.getStore('infostore'); console.log(level); console.log(level==this.getInfo1()); console.log(level==this.getInfo2()); var panel=level; store.load({ ....I write English by translator.
-
6 Nov 2012 2:51 AM #13
working good!! thanks again
alex


Reply With Quote