1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36
| var storeDGD = new Ext.data.ArrayStore({
fields: [
{name: 'PerLibAdr'},
{name: 'ProRef'},
{name: 'ForNom'},
{name: 'Info'},
{name: 'InfoDGD'}
]
});
var gridReportDGD = new Ext.grid.GridPanel({
store: storeDGD,
//Initialisation des colonnes
viewConfig: { //Fait en sorte que la somme des largeurs de colonnes soit égale à la taille de la grille
forceFit: true,
headersDisabled: true
},
columns: [
{header: "Nom", width: 250, dataIndex: 'PerLibAdr'},
{header: "DGD", width: 55, dataIndex: 'ProRef'},
{header: "Forêt", width: 200, dataIndex: 'ForNom'},
{header: 'Info', width: 25,dataIndex: 'Info',renderer:function(){
return '<img src="../img/plus.png" alt="Plus d\'informaiton" title="Information" />';
}},
{header: "InfoDGD", width: 0, hidden: true, dataIndex: 'InfoDGD'},
],
id: 'gridReportDGD',
name: 'gridReportDGD',
width: '100%',
//TODO LA HAUTEUR N'EST PAS OPTIMISEE
height: 275,
layout : 'fit',
border: false,
listeners:{
'rowclick': {fn: gridReportInfo}}
}); |
Partager