PDA

View Full Version : deferredRender does not display table layout correctly



omermx
5 Aug 2009, 6:25 AM
Hi, I have a user interface with several tabs. I need to populate the fields (in a table) in a tab that is not active.

I used deferredRender:'false' to get around errors since I was referring to fields that had not yet been rendered in my code.

However the table layout is all cramped together and is not spaced correctly like it is when deferredRender is set to true. See some code snippets below:



1. This is the table that is not rendering properly, it is in a fieldset within a FormPanel called 'createPatient'.



{
xtype:'fieldset',
id:'rx',
title: 'Rx Details',
collapsible: true,
collapsed:false,
animCollapse:true,
autoHeight:true,
border:true,
layout:'anchor',

items :[{
xtype:'panel',
layout:'table', height:160, anchor:'100%', style:'padding:5px',
defaults:{border:false, style:'font-size:13px'},
layoutConfig:{ columns : 11,
tableAttrs:{ cellspacing:'8'}},
items:[/*begin Right eye table*/
/* begin table headings, Right eye */
{},
{html : "Vision:"},
{html : "Sphere:"},
{html : "Cyl:"},
{html : "Axis:"},
{html : "VA:"},
{html : "Near Add:"},
{html : "V Prism:"},
{html : "H Prism:"},
{html : "NH Prism:"},
{html : "NV Prism:"},


2. This is the TabPanel container, the second tab contains the formPanel from 1.



items:[{xtype:'tabpanel', deferredRender:false, activeTab:0, id:'pa',
items:[
{title:'Personal Details', id:'pd', autoHeight:true, items:[Ext.getCmp ('createPatient')]},
{title:'Prescription (Rx)', id:'ps', autoHeight:true, disabled:false,
items:[Ext.getCmp('createPresc')]}, <----- !


Any help much appreciated!!!

5 Aug 2009, 6:29 AM
can you post a reproducable case??