PDA

View Full Version : In Extjs4.2.2 Column header height will get increase in IE-7,IE-8 for ColumnLock Grid



Vrushali.Suryawanshi
27 Jan 2014, 9:07 PM
In Extjs4.2.2 , Column header height will automatically get increase in IE-7 and IE-8 for Locking grid.

Can any one please help?

scottmartin
28 Jan 2014, 12:35 PM
I do not see this behavior, perhaps you can modify this code and send a screenshot?



Ext.onReady(function(){

Ext.create('Ext.data.Store', {
storeId : 'simpsonsStore',
fields : ['name', 'email', 'change'],
data : {'items' : [
{ 'name' : 'Lisa', 'email' : '[email protected]', 'change' : 100 },
{ 'name' : 'Bart', 'email' : '[email protected]', 'change' : -20 },
{ 'name' : 'Homer', 'email' : '[email protected]', 'change' : 23 },
{ 'name' : 'Marge', 'email' : '[email protected]', 'change' : -11 }
]},
proxy : {
type : 'memory',
reader : {
type : 'json',
root : 'items'
}
}
});

var grid = Ext.create('Ext.grid.Panel', {
title : 'Simpsons',
store : Ext.data.StoreManager.lookup('simpsonsStore'),

selModel: {
selType: 'cellmodel'
},

columns : [
{ header : 'Name', dataIndex : 'name', locked: true },
{ header : 'Email', dataIndex : 'email', flex : 1 },
{ header : 'Change', dataIndex : 'change' }
],
height : 200,
width : 400,

renderTo : Ext.getBody()
});

});

Vrushali.Suryawanshi
29 Jan 2014, 12:18 AM
Thanks, Issue resolved.

Previously I had given ID for each Column in grid as follows.


var grid = Ext.create('Ext.grid.Panel', {
title : 'Simpsons',
store : Ext.data.StoreManager.lookup('simpsonsStore'),

selModel: {
selType: 'cellmodel'
},

columns : [
{id:'1', header : 'Name', dataIndex : 'name', locked: true },
{id:'2', header : 'Email', dataIndex : 'email', flex : 1 },
{id:'3', header : 'Change', dataIndex : 'change' }
],
height : 200,
width : 400,

renderTo : Ext.getBody()
});

I got solution for same. Instead of Keeping ID as integer, if we given id as string as follows, then its working fine.

var grid = Ext.create('Ext.grid.Panel', {
title : 'Simpsons',
store : Ext.data.StoreManager.lookup('simpsonsStore'),

selModel: {
selType: 'cellmodel'
},

columns : [
{id:'nameColID', header : 'Name', dataIndex : 'name', locked: true },
{id:'emailColID', header : 'Email', dataIndex : 'email', flex : 1 },
{id:'changeColID', header : 'Change', dataIndex : 'change' }
],
height : 200,
width : 400,

renderTo : Ext.getBody()
});

scottmartin
29 Jan 2014, 4:49 AM
Yes, use of hard id's is not recommended due to collisions such as this. Use itemId instead.