PDA

View Full Version : Optimize form - slow load



jamesjara
25 Jun 2010, 8:42 PM
Hi friend , i think i need some tips, because a have a form, very slowly..

The form have like 29 checkboxgroups, this checkboxgroups have 5 checkbox each one.
Soo when i click en show the form, the Browser freezes for 5-8 seconds.

one more thing... the form load a record from store, soo each checkboxgroups is a field. In the store this field have this format ( 1,2,3,4,5,6 ) 0 to 100.

note: the json store load dont freezes.

example:



var ".$id_window_panel." = new Ext.form.FormPanel({
id : '".$id_window_panel."',
region : 'east',
width: 430,
margins: '4 4 4 0',
frame:true,
disabled :true,
items: {
xtype: 'fieldset',
title: 'Permisos',
autoWidth: true,
//maybe defaultType make slowly?
defaultType: 'checkbox',
//INICIA ITEMS checkbox
items: [
{
xtype: 'checkboxgroup',
name: 'C1' ,
fieldLabel: 'Escritorio',
items: [
{boxLabel: 'V', inputValue:'1' },
{boxLabel: 'A', inputValue: '2' },
{boxLabel: 'M', inputValue: '3' },
{boxLabel: 'E', inputValue: '4' }
]
},
{
xtype: 'checkboxgroup',
name: 'C2' ,
fieldLabel: 'Noticias',
items: [
{boxLabel: 'V', inputValue: '5' },
{boxLabel: 'A', inputValue: '6' },
{boxLabel: 'M', inputValue: '7' },
{boxLabel: 'N', inputValue: '8' }
]
},
//more 29 checkboxgroups. with unique name progessive.. C3,C4,C5,C6,C7..C28,C29
]
//
}
});

Animal
25 Jun 2010, 10:31 PM
So is it the initial render, or is it load which freezes?

jamesjara
26 Jun 2010, 1:48 PM
when load...

but I discovered the problem is exactly in the checkboxgroup , because I see in the ExtJS example http://www.sencha.com/deploy/dev/examples/form/check-radio.html , the frameset is COLLAPSE, so I apply that config to my frameset, NO MORE FREEZE in load form.
then
the form shows.. the frameset is COLLAPSED, i click in the frameset to openit..here the aplication freezes

The problem freeze is exactly in the frameset and checkboxgroup..

note: the frameset have like 29 checkboxgroup, with like 5 checkbox eachone

http://img8.imageshack.us/img8/1061/samplesb1.jpg
http://img8.imageshack.us/img8/1061/samplesb1.jpg