PDA

View Full Version : Optimization problem, getView Slow loading page



Nico-ProD972
24 Jan 2013, 8:58 PM
Hello all! I am French, sorry for the mistakes.
My problem is that my page takes about 1 minute 30 seconds to load, but I found it to be since I am sure to all grid panel refresh the page without the update page.
I had to load causing the click of the menu as this example:
verif function ()
{


alert ('VERIF to false')
return false;}
}


menu {
xtype: 'menu',
items: [{
text: 'RECIPE'
iconCls: 'edit',
handler: function () {


var = function verif ();
if (function == true) {var grid = Ext.getCmp ('monGridPanel14'). getView ();
grid.getStore (). load ();}


monGridPanel14.show ();
}
}]
}
So I thought to do a function verif () would be false from the beginning on and that would result in not charging 2 times the grid, but its not happening!
I also seek how to verif the function () to true: when we have finished loading the site!

mitchellsimoens
28 Jan 2013, 12:18 PM
The code you have provided doesn't look valid:


var = function verif ();

Nico-ProD972
28 Jan 2013, 9:46 PM
I had pasted the paragraph ,directly in google translate !!! :s
It's my fault!!
For call my function i do :
var fonction = function verif();
function verif ()
{
alert ('VERIF to false')
return false;}
}


menu {
xtype: 'menu',
items: [{
text: 'RECIPE'
iconCls: 'edit',
handler: function () {


var fonction = function verif ();
if (fonction == true) {var grid = Ext.getCmp ('monGridPanel14'). getView ();
grid.getStore (). load ();}


monGridPanel14.show ();
}
}]
}