PDA

View Full Version : grid show only single record



mortezakhadem
19 Feb 2011, 6:56 AM
hello
this ext javascript is not work exactly
show only one record and other records are hidden in html page

this.store = new Ext.data.JsonStore({
data: this.data,
idProperty: "Id",
fields: ['Id', 'Name', 'AttributeSetName', 'Price']
});
this.grid = new Ext.grid.GridPanel({
store: this.store,
columns: [
{
header: 'Id',
width: 60,
sortable: true,
dataIndex: 'Id'
},
{
header: 'Name,
sortable: true,
//renderer : 'usMoney',
dataIndex: 'Name'
},
{
header: 'Attribute set name',
sortable: true,
dataIndex: 'AttributeSetName'
},
{
header: 'price',
sortable: true,
dataIndex: 'Price',
renderer: function (value) {
return value;
}
}
],
renderTo: this.targetId
});

Ooypunk
20 Feb 2011, 3:33 AM
Where does the data (the input) come from? Is it formed correctly?

Condor
21 Feb 2011, 8:01 AM
You specified idProperty:'Id'. Are you sure the 'Id' contains unique values?

mortezakhadem
22 Feb 2011, 6:29 AM
i donot set height property
i set autoHeight:true